1
00:00:02,210 --> 00:00:05,160
Now that's it for this course section.

2
00:00:05,160 --> 00:00:08,210
We now had a thorough introduction into Express,

3
00:00:08,210 --> 00:00:11,760
which is a super important library for working with Node,

4
00:00:11,760 --> 00:00:13,670
and it's one of the most popular

5
00:00:13,670 --> 00:00:18,067
and commonly used NodeJS libraries that exists in the world.

6
00:00:18,067 --> 00:00:21,320
It's getting used by hundreds of thousands

7
00:00:21,320 --> 00:00:22,870
of developers every day.

8
00:00:22,870 --> 00:00:24,823
And now we got started with it.

9
00:00:25,862 --> 00:00:26,695
And you learned that Express,

10
00:00:26,695 --> 00:00:31,695
this library, is mainly dealing with routing requests.

11
00:00:31,970 --> 00:00:36,880
So with determining which path are request targets

12
00:00:36,880 --> 00:00:39,730
and which type of request it is,

13
00:00:39,730 --> 00:00:43,950
to then execute code for those different requests.

14
00:00:43,950 --> 00:00:45,630
And with help of Express,

15
00:00:45,630 --> 00:00:49,240
we can then send back tailored responses.

16
00:00:49,240 --> 00:00:51,170
We can send back responses that

17
00:00:51,170 --> 00:00:54,954
include dynamically generated data, if we need to.

18
00:00:54,954 --> 00:00:59,310
And we can also parse request data

19
00:00:59,310 --> 00:01:03,574
in case we get a post request that does carry such data,

20
00:01:03,574 --> 00:01:07,820
as long as we also add to this extra middleware,

21
00:01:07,820 --> 00:01:09,710
that was an important step,

22
00:01:09,710 --> 00:01:13,120
so that we also explicitly tell Express that

23
00:01:13,120 --> 00:01:15,910
it should parse and translate any data

24
00:01:15,910 --> 00:01:18,883
that might be attached to incoming requests.

25
00:01:19,860 --> 00:01:20,693
Now,

26
00:01:20,693 --> 00:01:22,614
we did also learn in this course section

27
00:01:22,614 --> 00:01:26,810
how we can then send back HTML content,

28
00:01:26,810 --> 00:01:30,100
at the moment, just stored in such strings,

29
00:01:30,100 --> 00:01:32,170
not in HTML files,

30
00:01:32,170 --> 00:01:35,291
but that will also change again in the future.

31
00:01:35,291 --> 00:01:40,291
And we learned that we can write and read to and from files.

32
00:01:40,920 --> 00:01:43,440
And that's of course not Express specific,

33
00:01:43,440 --> 00:01:45,590
but NodeJS in general,

34
00:01:45,590 --> 00:01:49,720
but we can utilize this when working with Express as well.

35
00:01:49,720 --> 00:01:52,010
And that's important to keep in mind

36
00:01:52,010 --> 00:01:53,915
and understand in general.

37
00:01:53,915 --> 00:01:58,915
Express does not replace NodeJS, instead it enhances it.

38
00:02:00,060 --> 00:02:04,100
We can now still use some core NodeJS functionalities,

39
00:02:04,100 --> 00:02:06,400
but we don't have to do everything

40
00:02:06,400 --> 00:02:09,167
in such a low level way as we did it before,

41
00:02:09,167 --> 00:02:14,167
where we manually had to check what our URL is and so on.

42
00:02:14,890 --> 00:02:16,910
Instead now we have a more structured

43
00:02:16,910 --> 00:02:19,980
and easier way of splitting our code

44
00:02:19,980 --> 00:02:22,310
and defining which code should execute

45
00:02:22,310 --> 00:02:23,920
for which kind of request.

46
00:02:23,920 --> 00:02:26,331
And we can then write any kind of logic

47
00:02:26,331 --> 00:02:28,553
our website might need.

48
00:02:29,580 --> 00:02:30,690
Now, last but not least,

49
00:02:30,690 --> 00:02:33,400
we also added NodeMon in the last lecture

50
00:02:33,400 --> 00:02:36,850
to make our life as a developer a bit easier.

51
00:02:36,850 --> 00:02:38,310
Now with all of that,

52
00:02:38,310 --> 00:02:40,270
we got a very solid foundation

53
00:02:40,270 --> 00:02:41,630
on which we can build up on

54
00:02:41,630 --> 00:02:45,000
to dive deeper into Express and Node.

55
00:02:45,000 --> 00:02:47,230
And to now in the next lecture,

56
00:02:47,230 --> 00:02:51,010
re-introduce separate HTML files,

57
00:02:51,010 --> 00:02:53,781
but this time, a bit more dynamic

58
00:02:53,781 --> 00:02:57,993
than the HTML files we worked on before in this course.

