-
-
Notifications
You must be signed in to change notification settings - Fork 358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
London 10 - Paulina Wywrot - Full Stack Assessment - Level 300 #372
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @PaulinaWywrot - very well-done, great job so far!
A general suggestion would be finding out where you could use useEffect
in your React app . Good luck with the next levels! 🥇
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking great, nicely put together!
import { useState } from "react"; | ||
|
||
const VideoCard = ({ video, removeVideo }) => { | ||
const [rating, setRating] = useState(video.rating); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like these ratings aren't stored in the database, so if you refresh the page they'll go away, and if multiple users look at the page they won't see each other's ratings. How would you add these to the database so that they're persisted?
updated url and status code
Co-authored-by: Daniel Wagner-Hall <[email protected]> Signed-off-by: PaulinaWywrot <[email protected]>
Thank you for your comments @ShadiSafaee, I've made some changes to my code :) |
updated rating: frontend (videoCard), backend (added put request); also amended get request (fetch video by id)
Hello @illicitonion, thank you for your review. I've implemented some changes as suggested, but please let me know if you have any further suggestions:) |
No description provided.