-
Notifications
You must be signed in to change notification settings - Fork 759
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
detectEvents() results in Turbolinks is not defined #743
Comments
Same issue here, can it be used without Turbolinks? Our app extensively use react-router, that conflicts with Turbolinks, would go for disabling the latter, but breaks page loading. We're calling mountComponents() manually as well, but nothing happens |
It looks like this line is causing the error, right?
Maybe the file should be update to something like if (typeof Turbolinks !== "undefined" && ...) ? |
Can we make a PR on this? @reactjs |
@rmosolgo Can you give me permission on NPM please? I'll push this out as part of 2.3.1 I think. Thanks. |
Very cool :) I added you as a collaborator, I think that should do it! https://www.npmjs.com/package/react_ujs |
Help us help you! Please choose one:
react-rails
, so I've included the stack trace and the exact steps which make it crash.react-rails
with another library, but I'm having trouble. I've described my JavaScript management setup (eg, Sprockets, Webpack...), how I'm trying to use this other library, and why it's not working.I've tried this in a large react-rails app that I've been trying to upgrade to 2.0 as well as a fresh app, neither of which includes turbolinks. I was attempting to debug why
ReactRailsUJS.mountComponents()
doesn't seem to be running automatically, which is what led me to attempt to callReactRailsUJS.detectEvents()
. I do not see any errors in the console when my page loads, only after callingdetectEvents()
.The text was updated successfully, but these errors were encountered: