April 2018
Intermediate to advanced
284 pages
6h 43m
English
In a React component, we can pass the properties from higher-level component, so knowledge of properties is a must, as it will give you more flexibility to extend your component and saves your time:
MyComponent.propTypes = { isLoading: PropTypes.bool.isRequired, items: ImmutablePropTypes.listOf( ImmutablePropTypes.contains({ name: PropTypes.string.isRequired, }) ).isRequired}
You can also validate your properties the way we can validate properties of Immutable JS with react immutable proptypes.