1
00:00:00,210 --> 00:00:00,550
All right.

2
00:00:00,580 --> 00:00:09,210
And the first fix that we have for our course, our duty is installing a course package on our express

3
00:00:09,240 --> 00:00:09,750
server.

4
00:00:10,320 --> 00:00:16,170
So pretty much there's package for everything, of course, is not an exception.

5
00:00:16,650 --> 00:00:19,020
So if you want to find out more info.

6
00:00:19,900 --> 00:00:26,770
I left here a link and effectively the idea is following again, we installed the package, which I'm

7
00:00:26,770 --> 00:00:32,770
going to do right away, so I'll stop it and then I'm going to go ampm and then start work.

8
00:00:33,100 --> 00:00:34,040
Sort of what am I doing?

9
00:00:34,060 --> 00:00:36,970
Why am I restarting the server without installing the package?

10
00:00:37,390 --> 00:00:38,240
My apologies.

11
00:00:38,500 --> 00:00:39,880
Let me grab this code.

12
00:00:40,860 --> 00:00:45,210
What installed the package again, like I said in the previous video?

13
00:00:45,750 --> 00:00:51,330
Technically, this is going to be a temporary fix and we'll use the proxy fix instead.

14
00:00:51,600 --> 00:00:55,890
So if you don't want to follow along, if you don't want to install the package, then you don't have

15
00:00:55,890 --> 00:00:56,440
to do that.

16
00:00:56,460 --> 00:00:59,550
Just kick back and relax and watch me struggle.

17
00:00:59,820 --> 00:01:05,010
Now it would be a better idea if I were to tell you that before I stopped serve, but hopefully you

18
00:01:05,010 --> 00:01:06,750
didn't waste too much time on that.

19
00:01:06,750 --> 00:01:09,430
So I'm going to go with npm starts now.

20
00:01:09,460 --> 00:01:16,510
I'm restarting the server and essentially the most straight up approach has fallen away.

21
00:01:16,950 --> 00:01:23,610
Just get the package and then I use it as a middleware, so I would go with I'm not used and would go

22
00:01:23,610 --> 00:01:24,240
with the course.

23
00:01:24,690 --> 00:01:32,040
Now there are some configuration options that I will very quickly discuss in the next video, but not

24
00:01:32,040 --> 00:01:32,460
for now.

25
00:01:32,940 --> 00:01:39,750
Let's just import and set it up on our server so we can successfully get the data on the frontend.

26
00:01:39,780 --> 00:01:41,220
So let me close the terminal.

27
00:01:41,700 --> 00:01:50,310
We are looking for server, so and then again, I will remove it so might as well do that.

28
00:01:50,610 --> 00:01:52,560
The top can be easier to find it.

29
00:01:52,560 --> 00:01:57,210
So course from and we're looking for a course package.

30
00:01:57,660 --> 00:02:02,880
We get the import and then above the express address on, I'm going to go with that.

31
00:02:03,600 --> 00:02:04,920
And let's go with the course.

32
00:02:05,250 --> 00:02:06,330
Let's save it.

33
00:02:06,900 --> 00:02:14,610
And now, if I go back to the dashboard and again, as I say, no, I'll just come on this one out because

34
00:02:14,790 --> 00:02:21,030
I do want to discuss the four slash in next video or set up the proxy, and I think it will help you

35
00:02:21,330 --> 00:02:26,550
to understand it better if I leave this data JSON example here.

36
00:02:26,910 --> 00:02:33,570
So let me just come on down one out and uncommon the 5000 and everything is correct.

37
00:02:34,020 --> 00:02:38,580
We're actually getting data is just, you know, our response is simple string.

38
00:02:38,940 --> 00:02:40,620
And here I'm looking for address on.

39
00:02:40,620 --> 00:02:48,030
So let me quickly fix this where instead of going with samples and I'm going to go with JSON again,

40
00:02:48,030 --> 00:02:50,850
this is dummy doesn't really matter how I structure it.

41
00:02:51,330 --> 00:02:53,070
And let's just set it up as an object here.

42
00:02:53,520 --> 00:02:58,620
And then I'm going to go with the message and I'll set it equal to my welcome.

43
00:02:58,980 --> 00:03:04,170
So a little bit of trickery effectively in order to get rid of that error.

44
00:03:04,170 --> 00:03:12,120
So I refresh and water, you know, I have message equal to your welcome, and hopefully this clearly

45
00:03:12,120 --> 00:03:14,460
showcases that everything works.

46
00:03:14,610 --> 00:03:17,190
We just need to install the course package.

47
00:03:17,580 --> 00:03:21,030
Set it up as our middleware on the server.

48
00:03:21,480 --> 00:03:23,040
One more time on the server.

49
00:03:23,040 --> 00:03:30,720
All of this is happening and not on the frontend will successfully be able to fetch the data, which

50
00:03:30,720 --> 00:03:33,190
essentially is how we'll build this project.

51
00:03:33,960 --> 00:03:40,590
All the resources are going to be located on a server and then from the frontend will just make fetch

52
00:03:40,590 --> 00:03:46,440
requests be ability because or Ajax requests, however you want to call them and then use the data to

53
00:03:46,440 --> 00:03:47,850
build our application.

