Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nicolasgandrade/node-blogapp
Blog App made with NodeJs and MongoDB database
https://github.com/nicolasgandrade/node-blogapp
authentication bcrypt blog express handlebars hash javascript login-system mongodb mongoose nodejs passport register sequelize
Last synced: 3 days ago
JSON representation
Blog App made with NodeJs and MongoDB database
- Host: GitHub
- URL: https://github.com/nicolasgandrade/node-blogapp
- Owner: nicolasgandrade
- License: mit
- Created: 2021-07-03T02:55:37.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2021-10-01T01:15:46.000Z (over 3 years ago)
- Last Synced: 2023-04-09T00:21:21.239Z (almost 2 years ago)
- Topics: authentication, bcrypt, blog, express, handlebars, hash, javascript, login-system, mongodb, mongoose, nodejs, passport, register, sequelize
- Language: JavaScript
- Homepage:
- Size: 4.28 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# NodeJs BlogApp
## π Blog App created with NodeJS and MongoDB### Features
- [x] Everybody is able to read posts
- [x] Categories filter
- [x] Register new user and admin account
- [x] Login into your account
- [x] Hashed passwords
- [x] Admin options: Create, edit and remove posts and categories
- [x] Logout system### Requirements
Before running the application, you must have NodeJs and MongoDB installed.
Make sure the mongo server is up before starting.### π² Running the Server
You can run the app using node command:
````node app.js````The blog is hosted on localhost port 8081 (localhost:8081).
Note: The database in MongoDB will be created automatically after the application starts.
### Main Routes
* /
* /users/register
* /users/login
* /categories
* /admin
* /admin/categories
* /admin/postsIf you want to register an admin user, you need to change the code inside *routes/user.js* **from this:**
````
const newUser = new User({
name: req.body.name,
email: req.body.email,
password: req.body.password
})
````
**to this**
````
const newUser = new User({
name: req.body.name,
email: req.body.email,
password: req.body.password,
isAdmin: 1
})
````
(lines 63/64 *routes/user.js*)
and then, reload the app and **register the new admin user.**### π» Technologies
The following tools were used in the construction of the project:
- NodeJs
- Express
- Handlebars
- MongoDB
- Bootstrap### Author
---
Made by Nicolas Guerreroπ