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

Don't need reload.js #76

Closed
ghost opened this issue Apr 28, 2017 · 5 comments
Closed

Don't need reload.js #76

ghost opened this issue Apr 28, 2017 · 5 comments

Comments

@ghost
Copy link

ghost commented Apr 28, 2017

In the sample express application. I found that it runs fine when I deleted the <script src="/reload/reload.js"></script> line. When do you need to include that tag?

@ghost ghost changed the title Dont Don Apr 28, 2017
@ghost ghost changed the title Don Don't need reload.js Apr 28, 2017
@alallier
Copy link
Owner

That's impossible it needs that script tag, so when the browser requests it, the express route created by reload will send the reload-client file.

@ghost
Copy link
Author

ghost commented Apr 28, 2017

I'll have another look at it

@ghost
Copy link
Author

ghost commented Apr 28, 2017

I cloned a fresh copy and it still worked. Heres what I did (in ubuntu terminal). Node version v6.10.2. Npm version v4.5.0.

$ git clone https://github.com/jprichardson/reload.git
$ cd reload
$ npm install # in reload directory
$ cd expressSampleApp
$ npm install # in reload/expressSampleApp directory

Then I removed the script tag, saved the file, and run:

$ ./node_modules/reload/bin/reload server.js -d ./public

@ghost
Copy link
Author

ghost commented Apr 28, 2017

Just had a look at the inspector in my browser. Turns out that reload-server.js is inserting the reload.js file into the webpage. I've made a pull request #79.

@alallier
Copy link
Owner

Please see comment left in #79. Going to close.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant