I’ve been playing around with the SAFE Browser for the past month but I still can’t manage to get webpack-dev-server working:
Is there a way/hack to fix this?
I’ve been playing around with the SAFE Browser for the past month but I still can’t manage to get webpack-dev-server working:
Is there a way/hack to fix this?
Currently it seems websockets crash electron with custom protocols (https://github.com/electron/electron/issues/10314), so I don’t think there’s a way for livereload.
You can turn off hot module replacement injection in webpack and get the benefits of constant recompilation, but you’ll be needing to refresh ma
nually though.
The Rotonde and Beaker communities are reporting quite a few ways to crash Beaker browser, which appear to be rooted in electron. Good news is that it appears to be a priority issue to be worked on.
Paul seems confident that it’ll be fixed by the release of Beaker 0.8.0
I’ve encountered the same problem before.
There has been a template that I was able to run successfully, although it includes Vue: vuejs-templates/webpack (documentation). Hot reloading worked perfectly, so you might take a look at the configuration of the template to figure out how it’s done.
Wow, that actually worked, thanks. I guess vue’s hot-reload is different form react’s in a way that makes it work on the SAFE Browser.
Glad it works!
That template just does not use a websocket out of the box. It uses an ‘eventsource’ stream.
I believe the error in your original post has to do with the socket library being fed a wrong URL. But, even a valid URL might not work, as @joshuef mentioned.
This topic was automatically closed after 60 days. New replies are no longer allowed.