Shopify / slate

Slate is a toolkit for developing Shopify themes. It's designed to assist your workflow and speed up the process of developing, testing, and deploying themes.
https://shopify.github.io/slate
MIT License
1.28k stars 364 forks source link

The connection to https://***.***.*.***:3001/__webpack_hmr was interrupted #932

Open radmedov opened 5 years ago

radmedov commented 5 years ago

Problem

Sometimes, when I press some link it just reloads the page and throwing an error:

The connection to https://***.***.*.***:3001/__webpack_hmr was interrupted while the page was loading.

Please advise.

Firefox Developer Edition 65.0b6

t-kelly commented 5 years ago

Haven't encountered this on my end. @chrisberthe have you hit this ever while developing?

bertiful commented 5 years ago

No I haven't encountered this issue. @radmedov, do you know of a way to replicate this on our end and we can look into it? Tbh, I rarely use Firefox during development but perhaps that could be part of it (although I highly doubt it's that).

dungle-scrubs commented 5 years ago

I've been experiencing this consistently as well in FireFox and FireFox Development Edition. I'm not sure how to troubleshoot it but it only happens in FireFox.

radmedov commented 4 years ago

The workaround: Go to: node_modules/webpack-hot-middleware/client.js and add this function

window.addEventListener("beforeunload", function(event) {
    handleDisconnect();
});

inside

function EventSourceWrapper() {