-
Notifications
You must be signed in to change notification settings - Fork 330
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
Possible install instruction change needed for Webpacker 6 #48
Comments
Sounds like Webpack is shaking its tree and not finding any usages of Turbo in the pack itself. @javan any idea how we might stop this from happening? Maybe with Webpack we shouldn't have the lib call start() itself. |
I'm experiencing the same with webpacker 5.1.1. To get around it I've added a I'm only using |
Does this "fix" it? - import { Turbo, cable } from "@hotwired/turbo-rails"
+ import "@hotwired/turbo-rails" |
Yes, this works fine. |
Yeah that worked for me under Webpacker 6 beta also. |
Thanks, same for vite For Turbo itself, this was not necessary, but ActionCable only worked in this way. |
I was trying to run the install instructions against the Webpacker 6 beta.
Taking my example which already worked against Webpacker 5, and upgrading Webpacker, my Turbo install was no longer downloading. (The links that had been identified in the log as being processed
as TURBO_STREAM
no longer were, the behavior was no longer working, and Turbo was no longer in the sources tab).Adding a
console.log(Turbo)
to theapplication.js
file makes everything work again, so I guess I'd assume that the switch to Webpacker 6 and thejavascript_packs_with_chunks_tag
helper somehow doesn't realize that Turbo is being used and therefore doesn't download it with the pack?Is there a preferred way of managing this?
Thanks!
The text was updated successfully, but these errors were encountered: