Skip to content

๐Ÿ•๏ธ YelpCamp2020 is my first Node.js web app following The Web Developer Bootcamp by Colt Steele, alongside some tweaks of my own.

License

Notifications You must be signed in to change notification settings

mitulagr2/YelpCamp2020

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

51 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Welcome to YelpCamp ๐Ÿ‘‹

๐Ÿ•๏ธ YelpCamp2020 is my first Node.js web app following The Web Developer Bootcamp by Colt Steele, alongside some tweaks of my own.

Table of contents

cover-art

What I Learnt

  • Introduction to Express.js.
  • Introduction to MongoDB database design.
  • Deploying the app to Glitch and Database to MongoDB Atlas.
  • Introduction to Model-View-Controller and Monolithic architectures.
  • Authentication and authorization using Passport.js.
  • Directory structure good practices.
  • Configuring Flash messages following user interactions.
  • Experimented with colorthief to apply dominant colour box-shadows in feed images.
  • Experimented with Paper.js to implement a custom 404 page.
  • RESTful routing (all endpoints listed below).
-------------------------------------------------------------------------
App Routes
-------------------------------------------------------------------------
[Method]  [Route]
GET       /                       Landing page
GET       /login                  User login page
POST      /login                  Authenticate existing user
GET       /signup                 User sign up page
POST      /signup                 Register new user
GET       /logout                 Logout and redirect to /posts
GET       /*                      404 page

-------------------------------------------------------------------------
Post Routes
-------------------------------------------------------------------------
[Method]  [Route]
GET       /posts                  Show all posts
POST      /posts                  Submit new post
GET       /posts/new              Add new post form
GET       /posts/:id              Show a single post
PUT       /posts/:id              Update a post
DELETE    /posts/:id              Delete a post
GET       /posts/:id/edit         Edit post page

-------------------------------------------------------------------------
Comment Routes
-------------------------------------------------------------------------
[Method]  [Route]
POST      /posts/:id/comments               Create a new comment
PATCH     /posts/:id/comments/:comment_id   Update a comment
DELETE    /posts/:id/comments/:comment_id   Delete a comment

Roadmap

  • Use CI/CD
  • Use Docker
  • Refactor
  • Rewrite using TypeScript
  • Use a CDN to deliver images
  • FEATURE: Allow uploading of images

Getting Started

Follow the steps below to run this project locally. Remember to create a .env file in the root directory and add the key DB_URL to it.

  1. Clone this repository.
# Clone repository
$ git clone https://github.com/mitulagr2/YelpCamp2020.git && cd YelpCamp2020
  1. Install dependencies via NPM or Yarn
# Install dependencies via npm
$ npm install

# Install dependencies via yarn
$ yarn install
  1. Run the server and open a browser to visit http://localhost:3000/.
# Run server
$ npm run dev

# Run server
$ yarn dev

Thank you very much!

Open to any suggestions on how to make this better! Feel free to fork the repo - Much appreciated!

About

๐Ÿ•๏ธ YelpCamp2020 is my first Node.js web app following The Web Developer Bootcamp by Colt Steele, alongside some tweaks of my own.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published