Skip to content

hollandjb92/YelpCamp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YelpCamp

YelpCamp is a web application built using Node.js, Express.js, RESTFUL Routing, EJS, and several other frameworks and middle-ware. This application is a makeshit-shift clone of Yelp that focuses on reviewing campsites and sharing information about them. It was made while completing The Web Developer Bootcamp course on Udemy

Getting Started

Follow these instructions to get a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

You will need Node.js and NPM installed on your system.

Installing

  1. Clone project:

     "git clone https://github.com/hollandjb92/YelpCamp.git"
    
  2. To install all the necessary npm packages, inside the root directory of the cloned filed, run the following command in your terminal/bash:

     "npm install"
    

Quick Look

yelpCamp HomePage

RESTFUL Routing

Application of REpresentational State Transfer (REST)

Campground Routes

Name Path HTTP Verb Purpose Mongoose Method
Index /campgrounds GET List all campgrounds Campground.find()
New /campgrounds/new GET Show a form to add a new campground N/A
Create /campgrounds POST Create a new campground, then redirect somewhere Campground.create()
Show /campgrounds/:id GET Show info about one specific campground Campground.findById()
Edit /campgrounds/:id/edit GET Show edit form for one campground Campground.findById()
Update /campgrounds/:id PUT Update a particular campground, then redirect somewhere Campground.findByIdAndUpdate()
Destroy /campgrounds/:id DELETE Delete a particular campground, then redirect somewhere Campground.findByIdAndRemove()

Comment Routes

Name Path HTTP Verb Purpose Mongoose Method
New /campgrounds/:id/comments/new GET Show a form to add a new comment N/A
Create /campgrounds/:id/comments/ POST Create a new comment, then redirect somewhere Comment.create()
Edit /campgrounds/:id/comments/:comment_id/edit GET Show edit form for one comment Comment.findById()
Update /campgrounds/:id/comments/:comment_id PUT Update a particular comment, then redirect somewhere Comment.findByIdAndUpdate()
Delete /campgrounds/:id/comments/:comment_id DELETE Delete a particular comment, then redirect somewhere Comment.findByIdAndRemove()

Built With