the create-react-app
tool automatically installs the latest react release. With these versions, the react-tap-event-plugin throws a whole bunch of errors. It appears FB's removed a bunch of libraries in the latest React releases that the react-tap-event-plugin
depends on and this will no longer work.
Module not found: 'react/lib/EventPluginHub'
Module not found: 'react/lib/EventConstants'
Module not found: 'react/lib/EventPluginUtils'
Module not found: 'react/lib/EventPropagators'
Module not found: 'react/lib/SyntheticUIEvent'
Module not found: 'react/lib/ViewportMetrics'
I find in issue #4670 that there are plans to remove the dependency in material-ui@next
but it has not yet when I tried upgrading to it. Basically I'm forced to downgrade everything to versions that worked for me last time.
"material-ui": "^0.15.4",
"react": "^15.3.2",
"react-dom": "^15.3.2"
Given the usefulness of create-react-app, it may be good to document this issue in the installation instructions and accelerate a push of material-ui@next
that fixes the issue
Looking forward for an update. Currently its a mess to downgrade a lot packages just because of this issue.
:( what's the solution to this? Stay on React 15.3.2?
There's a new version of material-ui and react out. Just upgrade them both.
Still blowing up for me:
Uncaught Error: Cannot find module 'react/lib/EventPluginHub'
Using:
"dependencies": {
"babel-plugin-transform-class-properties": "^6.18.0",
"material-ui": "^0.16.3",
"meteor-node-stubs": "^0.2.4",
"react": "^15.4.0",
"react-addons-pure-render-mixin": "^15.4.0",
"react-dom": "^15.4.0",
"react-mounter": "^1.2.0",
"react-tap-event-plugin": "^1.0.0"
}
You need to use the latest version of react-tap-event-plugin
which relies on the correct internal library from react-dom
instead of react
"react-tap-event-plugin": "^2.0.1"
Derp thanks. Didn't even see that it updated too- makes perfect sense.
@brendonlamb did it work for you after upgrading to React 15.4.0, react-dom 15.4.0, material-ui 0.16.4, react-tap-event-plugin 2.0.1? I am still having the issue, thanks for the help?
UPDATE: had to run npm install and all went fine (using the React Boiletplate). thanks all.
Just for reference too- using the latest version of everything at this point:
"dependencies": { "babel-plugin-transform-class-properties": "^6.18.0", "material-ui": "^0.16.3", "meteor-node-stubs": "^0.2.4", "react": "^15.4.0", "react-addons-pure-render-mixin": "^15.4.0", "react-dom": "^15.4.0", "react-mounter": "^1.2.0", "react-tap-event-plugin": "^2.0.1" }
"material-ui": "^0.16.4",
"react": "^15.4.1",
"react-dom": "^15.4.1",
"react-tap-event-plugin": "^2.0.1
I use the above versions but still I get the error Uncaught Error: Cannot find module 'react-dom/lib/ReactPerf' from 'react/lib/ReactAddonsDOMDependencies.js'
How to fix this?
@radik909 what @brendonlamb did works for me
@stevewillard Answered the question, thanks!
Most helpful comment
You need to use the latest version of
react-tap-event-plugin
which relies on the correct internal library fromreact-dom
instead ofreact
"react-tap-event-plugin": "^2.0.1"