![]() Difference from React.PropTypes: Don’t Call Validator Functionsįirst of all, which version of React are you using? You might be seeing this message because a component library has updated to use prop-types package, but your version of React is incompatible with it. ![]() Unfortunately there is no solution for this other than updating React to either 15.3.0 or higher, or 0.14.9 if you’re using React 0.14. It outputs warnings with the message below even though the developer doesn’t do anything wrong. npm install -save happens on other React versions? This package is compatible with React 15.3.0 and higher. # ATTENTION: Only run this if you still use React 0.14! How to Depend on This Package?įor apps, we recommend putting it in dependencies with a caret range. Note that this blog posts mentions a codemod script that performs the conversion automatically. Migrating from React.PropTypesĬheck out Migrating from React.PropTypes for details on how to migrate to prop-types from React.PropTypes. Refer to the React documentation for more information. Import React from 'react' import PropTypes from 'prop-types' class M圜omponent extends React.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |