bmustiata / fast-live-reload

A live reload that works with all the possible browsers.
18 stars 5 forks source link

http://localhost:9000/fast-live-reload/ not work properly. #5

Closed rudyhuynh closed 7 years ago

rudyhuynh commented 7 years ago

Step to reproduce:

  1. Go to http://localhost:9000/fast-live-reload/
  2. Type in address input: http://localhost:9000/my-file.html
  3. Edit my-file.html

Actual: Browser refresh to http://localhost:9000

Expected: Browser refresh to http://localhost:9000/my-file.html

bmustiata commented 7 years ago

Hi rudy, what is the command are you running?

rudyhuynh commented 7 years ago

fast-live-reload -s ./outputs

bmustiata commented 7 years ago

@rudyhuynh Thank you a lot for the bug report.

The bug is that the reload injection script is being injected inside the iframe as well, and I will fix this this evening. I'm just building a test to ensure it will never happen again.

But since you're already serving a folder, why don't you just try to access the file directly? Like just going to: http://localhost:9000/my-file.html in the browser? fast-live-reload is by default injecting a script into the page, in order to do the reload automatically.

The IFrame reloading is for sites that do redirects back to the site itself due to security reasons, so you can't just proxy them with -s http://site/....