Closed NickPadilla closed 7 years ago
@NickPadilla Since systemjs-hot-reloader
is never imported by your app, it doesn't get added to the bundle (which is traced from base
). To solve just include systemjs-hot-reloader
in your bundle. Something like jspm bundle base + systemjs-hot-reloader app/base-bundle.js --inject --minify
Closing, if still not working feel free to reopen :)
@alexisvincent I'm having this problem. I tried with your code without success, because it only bundle to a single file. I'm using v1.1.0. I don't want to modify my code for production either. Any advice? Thanks
It's suppose to bundle to a single file though?
Sorry I just read this today. I thought that this command jspm bundle base + systemjs-hot-reloader app/base-bundle.js --inject --minify
will bring the hot-reloader to the bundle (and I think it will do it), but then when this line is called SystemJS.import('systemjs-hot-reloader')
, I think that is looking for it outside the bundle because I get GET http://localhost:8000/systemjs-hot-reloader 404 (File not found)
. But commenting the line importing hot-reloader will make the app work. Sorry if this is not an issue for this package but I found it searching for help with production bundle including systemjs-hot-reloader
Hmm, weird. If you do a string search inside your bundle, can you see the systemjs-hot-reloader library? Are you loading the JSPM config? Sorry this took so long, under a lot of work pressure.
No problem, we are working with the workaround for the time being. I can see the following:
Main\app-bundle.js
Main\DefaultTabs.aspx
Chrome DevTools
jspm.config.js
Is systems-hot-reloader/dist/index.js
being injected into the bundle?
I wonder if you aren't perhaps bundling in production mode and then loading it in development mode. Can you try set both to dev?
Hello!
Great work on this project, thanks a heap! When i am doing a
jspm bundle base app/base-bundle.js --inject --minify
and i try running that build using the original index.html - i get this error in the console.GET http://localhost:8000/systemjs-hot-reloader 404 (File not found) N @ fetch.js:32 (anonymous) @ instantiate.js:165
I am just running this using
python -m SimpleHTTPServer
.I was under the impression that systemjs-hot-reloader would get written out during the build, or just providing a stub implementation. If i try to add ta map field in the jspm.browser.js to not load systemjs-hot-reloader then i get an error that
connect()
is not a function.Is there a way to tell the JSPM build to build for production, thought it was the default, so that i don't have to really edit my index.html for production?