-
Notifications
You must be signed in to change notification settings - Fork 74
Mini challenge 4 state management #52
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
base: master
Are you sure you want to change the base?
Mini challenge 4 state management #52
Conversation
…/github.com/lex-villa/react-certification-2020 into Mini-Challenge-1--Core-Concepts-and-Styling
…and-Styling Mini challenge 1 core concepts and styling
erickwize
left a comment
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.
Comments
Good work Gio!
Please create the PR into your own branch, that way we can only give feedback on the added code, not the whole project.
I encourage you to do testing, so we can give you the Bootcamp certification.
Acceptance Criteria
- The search term is stored and retrieved from the Global Context correctly.
- The appearance theme is stored on the Global Context and applied correctly to the App UI.
-
useReducerhook is implemented correctly to manage the Global State.
Bonus Points
- Testing coverage is above 70%. (Please include a screenshot of the code coverage report in your PR description).
| @@ -0,0 +1,3 @@ | |||
| REACT_APP_GOOGLE_API_KEY=AIzaSyDN0P1UB4W39-XdmmA9wniCAlXA0f3WprU | |||
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.
I recommend removing this file, you should never upload these types of files
| useLayoutEffect(() => { | ||
| const { body } = document; | ||
| const App = () => { | ||
| const state = useContext(Context)[0]; |
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.
I recommend using:
const [state] = useContext(Context)
| console.log('lista en video sugges'); | ||
| console.log(videosSuggested); |
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.
I suggested removing console.log from the code base
|
|
||
| const SearchInput = () => { | ||
| const [inputValue, setInputValue] = useState(''); | ||
| const dispatch = useContext(Context)[1]; |
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.
I recommend using: const [, dispatch] = useContext(Context)
No description provided.