Hoot Front-End Setting the Stage

Learning objective: By the end of this lesson, students will be able to conceptualize this application’s features and high-level architecture.

What we’re building - Hoot: Blogging for night owls

Landing

In this module, we will create a front-end blogging application using React and JWT Authentication. Pairing this front-end app with an Express API back-end and MongoDB database will yield a complete MERN Stack application.

JWT Authentication has already been implemented, allowing users to sign up, sign in, and sign out of our application.

Users with an account will be able to create, read, update, and delete blog posts. For branding purposes, we’ll refer to these blog posts as ‘hoots’. Additionally, signed-in users will be able to create and read comments associated with a specific hoot.

In building this application, you’ll get hands-on experience with several patterns fundamental to React, including client-side routing with the React Router library, dynamically rendering content based on permissions, and implementing reusable components.

Take a look at the screenshots below for a sense of the core components that will go into this application:

List page

Details page

New page

🚀 The screenshots above depict the application after completing all styling in the Level Up lessons.

User stories

Below are the user stories we will implement within Hoot:

💡 The above user stories give us a good idea of what CRUD operations a user might want to perform in our app.

Component hierarchy diagram

After reviewing the user stories, our next step is to map out the component structure of our React app. For this, we’ll utilize a Component Hierarchy Diagram. This visual tool will act as an outline of the tree structure in our client-side app.

Below is the component hierarchy diagram for the MVP build of Hoot:

Component hierarchy diagram

💡 Notice how most of our components will require a client-side route. This is because we treat these components as distinct pages in our app. Components not marked as requiring a route will be used as subcomponents making up the UI of a page.