A simple express web server that implement EJS as page template. Live demo is available on Railway free-tier.
- General Info
- Technologies Used
- Features
- Screenshots
- Setup
- Usage
- Project Status
- Lesson Learned
- Room for Improvement
- Acknowledgements
- The webpage allow user to compose a simple blog with content.
- The homepage of the website will show the first 100 letters of blogs post.
- The post page will show the whole content of the post.
- A practical project created for study and practice
- Express: ^4.16.3
- Node: ^14.17.6
- ejs: ^3.1.8
- lodash: ^4.17.21
- mongoose: ^6.6.1
- Create blog post
- Delete blog post
- Project environment:
- Node.js installed.
- MongoDB Shell installed.
- Cloud Database environment (Optional):
- Create a mongoDB Atlas account
- On project terminal
- install dependencies
npm install
- start the app
npm app.js
- install dependencies
- On Mongodb Shell
- start the database server
mongosh
- start the database server
- Or MongoDB Atlas (Optional):
- Connect to your database via mongoose with the URI of your database (remember to change the information of username,password,clustername and password accordingly)
- You should be able to get a customized URI from your account
- For more detailed information and documentation, please visit mongoDB doc website mongoDB/docs
mongoose.connect("mongodb+srv://<username>:<password>@<clustername>.mongodb.net/<databasename>?w=majority");
Project is: complete
- Implement EJS template page to simplify the web development process.
- Passing variables through express.
- Use express route parameters for useful purposes.
Connect to cloud database.Hosting on other platform other than Heroku.
To do:
Establish connection with cloud database (MongoDB Atlas).Hosted on Railway.
- This project was inspired by Angela Yu.
- This project was based on this course on Udemy.