|
63 | 63 | - [Passing a user custom reducer](#passing-a-user-custom-reducer)
|
64 | 64 | - [Exposing the internal reducer and types](#exposing-the-internal-reducer-and-types)
|
65 | 65 | - [**Section 12: (Bonus) Classifying the Patterns: How to choose the best API**](#section-12-bonus-classifying-the-patterns-how-to-choose-the-best-api)
|
| 66 | + - [How the classification works](#how-the-classification-works) |
| 67 | + - [Making the right API choice](#making-the-right-api-choice) |
66 | 68 |
|
67 | 69 | ## **Section 1: Introduction**
|
68 | 70 |
|
@@ -602,7 +604,6 @@ const withClapAnimation = WrappedComponent => {
|
602 | 604 | ### New to hooks?
|
603 | 605 |
|
604 | 606 | - [Hooks API Reference](https://reactjs.org/docs/hooks-reference.html)
|
605 |
| -- [useHooks](https://usehooks.com/) |
606 | 607 |
|
607 | 608 | Basic Hooks
|
608 | 609 | - [Using the State Hook](https://reactjs.org/docs/hooks-state.html)
|
@@ -642,6 +643,8 @@ useAdvancedPatterns()
|
642 | 643 | Open-source examples
|
643 | 644 |
|
644 | 645 | - [react-use](https://github.com/streamich/react-use)
|
| 646 | +- [useHooks](https://usehooks.com/) |
| 647 | +- [beautiful React hooks](https://github.com/beautifulinteractions/beautiful-react-hooks) |
645 | 648 | - [React Table](https://github.com/tannerlinsley/react-table)
|
646 | 649 |
|
647 | 650 | | Pros | Cons |
|
@@ -2644,4 +2647,20 @@ const Usage = () => {
|
2644 | 2647 |
|
2645 | 2648 | ## **Section 12: (Bonus) Classifying the Patterns: How to choose the best API**
|
2646 | 2649 |
|
| 2650 | +### How the classification works |
| 2651 | +
|
| 2652 | +- User Interface <-> Logic (x-axis) |
| 2653 | +- Difficulty (y-axis) |
| 2654 | +
|
| 2655 | +**[⬆ back to top](#table-of-contents)** |
| 2656 | +
|
| 2657 | +### Making the right API choice |
| 2658 | +
|
| 2659 | +| Difficulty | User Interface | User Interface and Logic | Logic | |
| 2660 | +| :----------- | :------------------ | :------------------------- | :----------- | |
| 2661 | +| Easy | Reusable Styles | Props Collection & Getters | | |
| 2662 | +| Intermediate | Compound Components | State Initialisers | Custom Hooks | |
| 2663 | +| Hard | | Control Props | | |
| 2664 | +| Hard | | State Reducer | | |
| 2665 | +
|
2647 | 2666 | **[⬆ back to top](#table-of-contents)**
|
0 commit comments