Frontend Routes - DavidPhamThinkful/Life-Overflow GitHub Wiki
User-facing routes
/login
This page displays a log in form
GET /login
POST /login
/signup
This page displays a signup form.
GET /signup
POST /signup
/
This is our splash page, which displays cards for each category with a hyperlink to each category, which lists every question within the category, as well as a card that leads to all the questions. Every page will have a navigation bar with login/signup or logout buttons.
GET /
/questions
& /categories/:id
These pages lists all of the questions that belongs to their respective category or all question on the /questions
page. Each question has an edit and delete button if it belongs to the currently logged in user. Any user can select a question and be redirect to the questions page.
GET /questions
GET /categories/:id
/questions/new
This page displays a form with which a logged in user can craft a new question, as well as a navigation bar with logout button.
GET /questions/new
POST /questions/new
/questions/:id
This page displays individual questions with associated answers and votes, as well as a navigation bar with login/signup or logout buttons. If the logged in user owns the question, this page also displays an update and delete button. Logged in users can post answers on this page, and can vote on the answer. The logged in owners of those answers can update or delete them. Logged in users can change or remove their vote.
GET /questions/:id
GET api/questions/:id/answers
POST api/questions/:id/answers
PUT api/answers/:id
DELETE api/answers/:id
PUT api/answers/:id/votes