Skip to content

Frontend Routes

lk340 edited this page Jan 20, 2019 · 1 revision

Front-end Routes

Our components are organized as follows:

  • Root
    • App
      • NavBar (position: fixed with logo that links to index page, search input, and explore/likes/profile)
      • (main component goes here)
      • Footer (bottom-right in index page, fixed to bottom under 'explore' and 'profile' pages)

The following routes, defined in App, will render components between NavBar and Footer.

  • /
    • SessionForm (sign-up) (if there is no user signed in)
    • PostsIndex (if there is a user signed in)
  • /accounts/signin
    • SessionForm (sign-in)
  • /accounts/edit
    • Edit user info
  • /users/:userId
    • Profile Component (renders profile picture, user info, #posts, #followers, #following, edit profile button and edit account button)
    • PostIndex Component (renders all of user's posts)
  • /posts/new
    • PostForm
  • /post/:postId
    • PostShow
  • /posts/:postId/edit
    • PostForm
  • /saved
    • SavedPostsIndex

Clone this wiki locally