Last active
January 23, 2016 13:00
-
-
Save eyakcn/3c89ba5ee79cd6635369 to your computer and use it in GitHub Desktop.
Reactjs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <input ref={node => { this.input = node; }} /> | |
| Things you should never do inside a reducer: | |
| Mutate its arguments; | |
| Perform side effects like API calls and routing transitions; | |
| Calling non-pure functions, e.g. Date.now() or Math.random(). | |
| TodoList.propTypes = { | |
| onTodoClick: PropTypes.func.isRequired, | |
| todos: PropTypes.arrayOf(PropTypes.shape({ | |
| text: PropTypes.string.isRequired, | |
| completed: PropTypes.bool.isRequired | |
| }).isRequired).isRequired | |
| } | |
| Footer.propTypes = { | |
| onFilterChange: PropTypes.func.isRequired, | |
| filter: PropTypes.oneOf([ | |
| 'SHOW_ALL', | |
| 'SHOW_COMPLETED', | |
| 'SHOW_ACTIVE' | |
| ]).isRequired | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment