reload.js is not found
See original GitHub issuethe reload isn’t working for me, and on checking direct access to the JS URL, the file isn’t being served.
http://localhost:4040/reload/reload.js
I added the file itself directly to my own pubilc/js dir and now things work fine.
any idea why the JS file isn’t automagically being served?
I’m using a vanilla express app setup with the generator so it’s quite confusing.
debug('using hot reloader');
var http = require('http');
var reloadServer = http.createServer(app);
let delay = 300;
reload(reloadServer, app, delay);
reloadServer.listen(app.get('port'), function() {
console.log("Reload server listening on port " + app.get('port'));
});
this block ^ also prints out the right port #
confused!
Issue Analytics
- State:
- Created 8 years ago
- Reactions:2
- Comments:25 (9 by maintainers)
Top Results From Across the Web
Simple javascript reload not working - Stack Overflow
reload () in the function refresh() and using onclick='refresh()' in a button. For some reason the page is not reloading. The JS function:...
Read more >location.reload() - Web APIs | MDN
The location.reload() method reloads the current URL, like the Refresh button. The reload may be blocked and a SECURITY_ERROR DOMException ...
Read more >Why Javascript location.reload does not work?
It could be that the reload somehow reloaded the cached version of the page. In that case, you can force it to reload...
Read more >reload - npm
Node.js module to refresh and reload your code in your browser when your code changes. No browser plugins required.. Latest version: 3.2.0, ...
Read more >Location Reload Method: How to Reload a Page in JavaScript
Optional parameters force reload is a boolean value, which if set to: True reloads the page from the server (e.g. does not store...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@alallier I resolved my problem. I had put
reload(server, app)
before error handlers .@EleanorMao It seems we are talking about two different problems here, one being you couldn’t get the sample app to work and second a websocket issue.
Why didn’t the sample app work? Can you provide more details here?
Same for the second comment.
The first step is to see why you can’t run the sample app and then worry about integrating reload later.