Open drewchandler opened 9 years ago
Yeah, I've had the same thought. I'm currently using this with an in-app addon that is basically ember-cli-live-reload but loads the js resource with a full path.
Another possibility is that this addon could include its own middleware for live reloads. I wanted to add middleware anyhow to support CORS in for font requests.
Here is the work around I am using in my Rails app using the rack-forward gem.
In config/environments/development.rb
:
config.middleware.use Rack::Forward do |req|
if req.path == '/ember-cli-live-reload.js'
URI.parse('http://localhost:4200/ember-cli-live-reload.js')
end
end
I've used a http proxy to work around this as well. Ideally, however, users of the addon wouldn't have to resort to something like this and live reload would Just Work™
The injected live reload tag isn't affected by the fingerprinting prepend option so it 404s.
Maybe the real issue is that ember-cli-inject-live-reload needs to be more configurable?