Categories Futureflix

12 posts

Auto Added by WPeMatico

🌟 learn hapi β€” Update Mongoose Models for JSON Responses

While creating the Futureflix API, you noticed that the JSON representation of documents contains the _id and version key __v. The _id field feels wrong due to the underscore prefix, so let’s remove it and keep only the id field. The version key __v isn’t necessary in the response at […]

🌟 learn hapi β€” Generate a Username in Mongoose Middleware

You added a profile editing screen in the previous tutorial. This profile editing view lets users update their personal username and homepage. Up to this point, each user has a blank profile after signing up. Following this tutorial, you’ll generate a username based on the user’s email address when saving […]

🌟 learn hapi β€” Add CSRF Protection on Forms and API Endpoints

During the last weeks, you made tremendous progress on β€œlearn hapi” and your Futureflix app grows in functionality. Up to this point, you rely on hapi’s built-in security mechanisms. We didn’t care about adding custom protection yet (which is totally fine). That changes now and it’s what you’ll tackle in […]

🌟 learn hapi β€” Implement a User Profile Editing Screen

You probably follow along this β€œlearn hapi” learning path and your Futureflix app already contains a sign up and login to onboard users. But there’s no personal user area. Users can’t edit their information in a profile editing screen, yet. At the end of this tutorial you’ll have this functionality […]

🌟 learn hapi β€” Load the User’s Profile Picture From Gravatar Using Virtuals in Mongoose

Using Gravatar for profile pictures feels like the snake game on Nokia phones. You know, the Nokia phones that are still charged if you’d find one in your winter jacket πŸ˜„ The older Nokia phones with model names like β€œNokia 3210” used to have a game installed called β€œsnake”. You […]