Reading--Notes

1. How would you break a mock into a component heirarchy ?

The first thing you’ll want to do is to draw boxes around every component (and subcomponent) in the mock and give them all names

2.What is the single responsibility principle and how does it apply to components ?

single responsibility principle is that a component should ideally only do one thing. If it ends up growing, it should be decomposed into smaller subcomponents.

3. What does it mean to build a ‘static’ version of your application ?

The easiest way is to build a version that takes your data model and renders the UI but has no interactivity. It’s best to decouple these processes because building a static version requires a lot of typing and no thinking, and adding interactivity requires a lot of thinking and not a lot of typing.

4. Once you have a static application, what do you need to add?

To make your UI interactive, you need to be able to trigger changes to your underlying data model. React achieves this with state.

5. What are the three questions you can ask to determine if something is state ?

6. How can you identify where state needs to live?