-
Notifications
You must be signed in to change notification settings - Fork 188
Open
Description
First of all, thank you for implementing issue #17!
My asset hrefs contain a digest/hash, i.e. the main.css on disk is referenced as main.eec09356.css in the HTML (which is then rewritten to main.css by the webserver). The "changed" URL sent to livereload-js is just main.css. Therefore nothing matches with reloadMissingCSS = false.
I think I'd have to modify the pathFromUrl function to support this setup:
path = path.replace(/\.[0-9a-f]{8}\./, '.');
What would be the best way to make this feature optional / configurable such that it can be merged? Maybe a new pathFromUrl option that (if present) would be used instead of the default pathFromUrl function?
window.LiveReloadOptions = {
pathFromUrl: function(url) {
return url.replace(/\.[0-9a-f]{8}\./, '.');
}
};
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels