Routing in Node.js. A route is really just a URL pattern. So for example when a user tries to go to a web page that loads or runs this specific URL it goes to this routing system. And the routing will look at that URL or the endpoint and find a matching file to send that back to the user, right? So if you might have another pattern that might go to the about page and again the system will fetch the about html document back to the user and so on. So that's how our system works. It's just a mechanism of how to route or direct a user to a very specific a document on the website. So let's see how this is done in Node.js.
All right, so back in the ID here which is going to go into the app example that we did earlier with the get post and put in the lead request types here. And we're going to put in here some routes to pull the correct data to the user. So I'm going to go in here and type a route. So let's just say that if the user lands in the URL with a slash get, you're going to get this document or this data to be visible to be sent to the browser. So I'm going to just tap this little bit over, include this inside each route. And let's just say that the first route. So if the first route in this case would be coming from the request that URL if this URL is equal to this route, this is the root directory, right? But I want to have the one that says get if it goes to get then it's going to load this page on this document here in just this section alone, okay? And then else if it's a different route.