Skip to content

Commit 1de6e63

Browse files
committed
Merge branch 'master' of github.com:leanjscom/thinking-in-react
2 parents 64c1bc5 + 855cdc0 commit 1de6e63

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ You need to have `node`and `npm`installed in your computer.
1212

1313
## Exercise
1414

15+
Before you start, there are two types of components [Functional Components and Class Components](https://reactjs.org/docs/components-and-props.html#functional-and-class-components). Try to use a Functional component if the component doesn't have state, you'll need to refactor code a few times during the next exercise :)
16+
17+
### Tasks
18+
1519
1- Refactor the “about” and “footer” sections by creating a stateless component for each. Make sure everything works.
1620

1721

@@ -21,14 +25,19 @@ You need to have `node`and `npm`installed in your computer.
2125
3- Refactor the books section by creating a stateless component and pass the dependencies via props. Make sure everything works.
2226

2327

24-
4- Is there any state in app that should be in the Books component? Refactor <Books> books if appropriate. Should <Books> be a stateless component or a class now?
28+
4- Is there any state in app that should be in the Books component? Refactor &lt;Books&gt; books if appropriate. Should &lt;Books&gt; be a Functional Component or a Class Component now?
2529

2630

27-
5- Break <Books> down into <BookList> and <BookFilter>
31+
5- Break &lt;Books&gt; down into &lt;BookList&gt; and &lt;BookFilter&gt;
2832

2933

3034
6- What do you think it would make sense to componentize next? Are there any parts on that view that you can reuse? Try to explain to a mentor what you want to refactor before you code :)
3135

36+
### Links
37+
38+
* [https://reactjs.org/docs/introducing-jsx.html](https://reactjs.org/docs/introducing-jsx.html)
39+
* [https://reactjs.org/docs/thinking-in-react.html](https://reactjs.org/docs/thinking-in-react.html)
40+
* [babel repl example](https://babeljs.io/repl/#?babili=false&browsers=&build=&builtIns=false&code_lz=MYewdgzgLgBAEgUwDZJAYRAWwA7gWWAXhgAoBKGQgPlICgYYAeAEwEsA3K-hpgCwEYqiFCACEjAPQCuPJtioB1ZKEwIYUEEwCGMXgCcEAM0IAiXlCjYIALgkSDW4FABWEAHSOtzBJgCeJqgAlBEcoACkAZTcAQWAvH19JLSpJeW5JNk5aMgBuWloWDhhgJC0ICAA5LVVTUAItVjAEPQD0zOLS8qqakz0QAHdW2QBvYVQMHDwCAF90iUyuDI4qIA&debug=false&forceAllTransforms=false&shippedProposals=false&circleciRepo=&evaluate=true&fileSize=false&lineWrap=false&presets=es2015%2Creact%2Cstage-2&prettier=false&targets=&version=6.26.0&envVersion=)
3241

3342
## License
3443

0 commit comments

Comments
 (0)