Skip to content

Instantly share code, notes, and snippets.

@james2doyle
Created July 23, 2020 16:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save james2doyle/ec0e8b3aed3b2acdb7dd44d22f2139e1 to your computer and use it in GitHub Desktop.
Save james2doyle/ec0e8b3aed3b2acdb7dd44d22f2139e1 to your computer and use it in GitHub Desktop.
Simple hot reload snippet
if (module.hot) {
// reload the page when this global code is changed
module.hot.accept([
'./hot-reload.js', // same name as this file!
], window.location.reload);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment