We've moved discussions to Discord

Guard and Rack not working for livereload

Joshua L Handel
When I use "foreman start" or "bin/dev" to run my dev server then the URL for the livereload.js has a .min added to it for some reason and there for 404's (http://localhost:35729/livereload.min.js? net::ERR_ABORTED 404 (Not Found)) 

when I use "rails s" to run the dev server the livereload.js loads via the URL "/__rack/livereload.min.js?host=localhost". But then I get the error "LiveReload disabled because it could not find its own <SCRIPT> tag"

Been banging my head against a wall for a while trying to figure this out but there is nothing in any configurations that explain either where the .min is coming from for the guard/foreman approach or why the "script" tag is mal-formed or missing for the rack approach.. 

Environment:
100% running in WSL2 (no windows hosted services so rails, pg, redis, etc are all in linux) Ubuntu 20.04 LTS (GNU/Linux 5.10.102.1-microsoft-standard-WSL2 x86_64)

Any help or other ways to get live-reloading working would be awesome!
Joshua L Handel
As a note, http://localhost:35729/livereload.js does load fine with foreman or bin/dev, but I can't find a configuration or something in the middle ware (even in the source code of guard) that is triggering this .min. to be added to the URL
Andre Arko
I strongly recommend using hotwire-livereload instead: https://github.com/kirillplatonov/hotwire-livereload.
Joshua L Handel
Andre Arko I'll give it a shot, though not all my pages use turbo so... but hey if it works :-).. 

Still doesn't solve for why the out of the box stuff doesn't seem to be working currently.... not sure if that is worth chasing down or if new guidance in the docs should be shared..  (yes that is all a  Chris Oliver   thing but still worth sharing to the ether)
Notifications
You’re not receiving notifications from this thread.