New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: _react2.default.createClass is not a function #110
Comments
The code needs to be changed for React v16 .. the create class has moved to a separate require. EDIT: spotting the error is much easier than correcting it ! I did a clone and took a look at the code. The files that need changing on my installation are in
e.g.
needs to change to
or similar. The trouble is when I clone the code, the lib directory doesn't contain these files. Can anyone explain ? Malcolm |
@harrowm That's because the |
What is the status of this issue? |
This is due to react version 16 not supporting for createclass. I could overcome by downgrading react and reactdom to version 15. Basically update you package.json file for react and reactdom to version 15. And run npm install again |
Downgrade is not an option because in my app I make use of fragments, portals and so on. |
Use react-formio v2.0 or higher which supports react 16. The react-formio v1.x uses createClass extensively which won't work in react 16. |
./node_modules/react-formio/lib/components/FormComponents/address.js
node_modules/react-formio/lib/components/FormComponents/address.js:25
22 |
23 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
24 |
The text was updated successfully, but these errors were encountered: