You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The favoriteMovies state is currently managed locally in the FavoritesButton component. favoriteMovies is also required to display the users favorite movies in ProfileView.
Proposed Solution
Use Redux to manage the favoriteMovies state globally.
Dispatch actions to fetch the initial favorites and update the list when users add or remove a movie.
Refactor components like FavoritesButton and others that need favoriteMovies to connect to the Redux store.
Benefits
Simplifies data management
Reduces API calls
SSOT
The text was updated successfully, but these errors were encountered:
samanthasbytes
changed the title
Refactor favoriteMovies state to use Redux for global accessibility
Refactor favoriteMovies state to use Redux
Dec 5, 2024
samanthasbytes
changed the title
Refactor favoriteMovies state to use Redux
Manage favoriteMovies with Redux
Dec 5, 2024
Problem
favoriteMovies
state is currently managed locally in theFavoritesButton
component.favoriteMovies
is also required to display the users favorite movies inProfileView
.Proposed Solution
favoriteMovies
state globally.FavoritesButton
and others that needfavoriteMovies
to connect to the Redux store.Benefits
The text was updated successfully, but these errors were encountered: