Skip to content
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

LiveReload script fails to load on Firefox #74

Closed
O-J1 opened this issue Mar 7, 2019 · 3 comments
Closed

LiveReload script fails to load on Firefox #74

O-J1 opened this issue Mar 7, 2019 · 3 comments
Labels
S: needs-confirmation The alleged behavior needs to be confirmed.

Comments

@O-J1
Copy link

O-J1 commented Mar 7, 2019

Firefox: 65.0.2
Sublime: 3.1.1, Build 3176
OS: Windows 10 (Version 10.0.17134.590)
Markdown Preview: Installed through Package Control
Live Reload: Installed through Package Control
Live Reload Broweser Plugin: https://github.com/twolfson/livereload-extensions


Live reload does not work on Firefox when try to use it with Markdown Preview. Livereload is enabled and I have followed the documentation and I am just using the plain old markdown parser, nothing fancy.

When checking the console for the generated file, "loading failed for <script> ... " appears in the console:
image

All of my browser plugins are disabled on localhost files and live reload works when I normally insert the below snippet into a HTML document:
<script>document.write('<script src="http://' + (location.host || 'localhost').split(':')[0] + ':35729/livereload.js?snipver=1"></' + 'script>')</script>

The generated file markdown file uses async (it was mentioned in past issues as a fix for chrome?). Definitely not what is used/working on firefox. Unsure of how to modify it myself to correct what this plugin inserts

Thanks for the wonderful plugin.

Regards,
Xam

@facelessuser
Copy link
Owner

Supposedly the latest fix was tested in Firefox. It looks like it was tested specifically in macOS, not Windows. I'll have to try and confirm whether it works myself. I'll let you know when I have a chance to confirm.

@facelessuser facelessuser added the S: needs-confirmation The alleged behavior needs to be confirmed. label Mar 7, 2019
@Algomorph
Copy link

Algomorph commented Sep 15, 2020

Hi, thank you for this useful plugin!

I'm having a similar issue with Chrome 85.0.4183.102, not sure if it's duplicate, so I'll write here first.
I also followed the official instructions. LiveReload seems to reload the page when I save the file in Sublime, but the content isn't updated (and neither is the actual generated html on disk).

Sublime: 3.2.2
Markdown Preview: installed from Package Control just today (2.2.5?)
OS: Ubuntu 18.04.5 LTS
LiveReload: installed from Package Control.

Sorry, it does work for me if I save with the proper extension. I didn't realize that my file has to be in one of these extensions for the auto-reload to work / didn't notice this setting:

"markdown_filetypes": [".md", ".markdown", ".mdown"],

It may be worthwhile to put a note about this in the official instructions.

@facelessuser
Copy link
Owner

LiveReload has always been a pain, and can honestly be finicky. It is the solution that I inherited with the project when I took it over. TBH, I don't often use the live reload feature, but I'm glad you got it working.

If it helps, I do accept pull requests for documentation updates. But if no one makes one, I'll try and look at sometime later and see if we can improve the docs a bit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S: needs-confirmation The alleged behavior needs to be confirmed.
Projects
None yet
Development

No branches or pull requests

3 participants