Express essentials
- Express is a node framework
- Express can use template languages to create HTML, like Jade, Pug, Mustache, EJS, Dust, HBS, HJS, Twig, Vash
- Express Application Generator is a package used to create the boilercode for an Express application. link
This project was built following this tutorial
- Node 18.16.1
- Express 4.16.1
change directory:
$ cd testapp
install dependencies:
$ npm install
run the app:
$ DEBUG=testapp:* npm start
change directory:
$ cd express_essentials
install dependencies:
$ npm install
run the app:
$ npm start
$ npm debug
- localhost:3000
- localhost:3000/public/mountain_1.jpg
- localhost:3000/images/mountain_2.jpg
- localhost:3000/download
- localhost:3000/redirect
- localhost:3000/item (POST, send header and body in Postman { "item": "rollerblades"})
- localhost:3000/class (GET, POST, PUT)
- localhost:3000/next
- localhost:3000/class/:id
// Chaining
app
.route("/class")
.get((request, response) => {
throw new Error();
})
.post((request, response) => {
response.send("Create class info");
})
.put((request, response) => {
response.send("Update class info");
});
List of features:
- simple backend
- several routes to test the app
Project is: done
Project by Linkedin
By bermarte