- Replace
<your_account>
with your Github username in the DEMO LINK - Follow the React task guideline
Implement FindMovie
component to load movies from OMDb API (You need to register and get an API key).
Don't use class components. Use React Hooks instead.
- When user enters a movie title and clicks a search button, send a request to
http://www.omdbapi.com/?apikey=[yourkey]&t=[title]
. - If film is not found show an error message below the input. Hide the error after changing a title.
- If a film has been found show the preview as a
MovieCard
. - Add a movie to the list after submitting a form and clear the input.
- Don't add the same film to the list twice (compare by
imdbId
).