Join Shaun Wassell for an in-depth discussion in this video Upvoting articles, part of React: Creating and Hosting a Full-Stack Site.
- [Instructor] Now that we've seen … some basic examples of how an express server works, … let's make our server do something … more relevant to our blog. … We'll want users to be able to upvote our articles … to help other users see which of our articles … is the most popular or most helpful. … And in order to do that, … we'll need to add some code to our back end. … Now, later on, we'll look at how … to add an actual database to our server, … but for now, we're just going to create a sort of fake database … which will keep track of the upvotes for our articles. … And, that's going to look like this. … Our fake database will simply be a JSON object … that we modify whenever specific routes are hit. … And the keys of this JSON object … will be the unique name fields … of our articles from our front end, … and the values will be JSON objects … Right now, this will just be the number of upvotes. … and we're going to define a new endpoint … that we can send requests to in order … to update the number of upvotes on a given article. …
- Creating the app component
- Using React-Router links
- Setting up an Express server
- Route parameters in Express
- Adding the comments functionality
- Installing and adding MongoDB to your project
- Rewriting the endpoints
- Adding React hooks
- Adding buttons and forms
- Pushing code to GitHub
- Running a full-stack app on AWS
Skill Level Intermediate
1. Creating a React Front End
2. Creating a Node Back End
3. Setting Up MongoDB
4. Connecting the Front and Back Ends
5. Hosting the Site
Next steps1m 17s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.