Open SylvieDoumet opened 4 days ago
Hey there,
Please include in the acceptance criteria, what happens if the movie cannot be loaded. Will there be a placeholder instead of the embedded video or an error message for the user?
We embedded an error handling functionality within the acceptance criteria & tasks
Value proposition
As a user of the homemade remedies app,
I want to be able to view preparation videos for each remedy directly on the remedy detail page,
So that I can better understand how to prepare the remedies with visual guidance.
Description
Acceptance criteria
Tasks
assets/remedies.json
with a youtube-url of a preparation video for each homemade remedy recipe. Use"videoUrlPreparation":
as key and embed the video IDs into the structurehttps://www.youtube.com/embed/videoID
pages/remedy/[id]/index.js
so that it contains aconst currentVideo = currentRemedy.videoUrlPreparation
and in the return a video container with an iframe sourced bycurrentVideo
. Style the videocontainer as a styled component (styled.div).next.config.js
so that the reactStrictMode accepts images and videos from the youtube domain_app.js
with a useEffect hook that re-renderes the initialRemedies when loading so that the newly added content appears - and there is no need to delete the local storage state every time the site is opendpages/remedy/[id]/index.js
so that a placeholder is displayed when a video can not be loaded