![]() GitHub profiles are all the rage at the moment. #A simple programming exercise using node.js xteam how toLearn how to use Async/Await in JavaScript ! If you want to start a blog as a developer, I recommend reading the article “ how to start your blog as a developer ”!ĭo you struggle to stay up-to-date with all news in tech? See one way to stay up to date as a developer ! Speed up your development with Git Aliases. Negotiating your salary is essential - learn how to negotiate your salary as a developer ! If you want to learn JavaScript, I recommend these 5 resources to learn JavaScript as a beginner ! If you want to make money with technical writing, check websites that pay you to write technical articles! If you are interested in JavaScript tutorials, I recommend Frontend Masters ! Now, if you go to you should see a webpage with a blue background - of course, that’s after you close the annoying pop-up. Write the following code in your file: app.get('/', (req, res) => ) COPY It also takes a function which is called when the endpoint is accessed. GET, POST, and so on), and it takes a URL path. A route is associated with an HTTP verb (e.g. In the simplest terms, a route represents an endpoint which people can access. In the second line, you call the express function, which creates a new application and then assigns the result to the app constant.Ĭreate routes and listen on a specific port.Each time you add a package to your project, you need to import it where you want to use it. With the first line, you import Express into your project so you can use it.Open the file, and start by writing the following lines: const express = require('express') const app = express() You can do so by running the following command in your terminal: touch index.js Before proceeding further, you need to create the JavaScript file for the web server. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |