zodern / melte

Svelte compiler for Meteor with built in tracker integration and HMR
MIT License
33 stars 14 forks source link

Failed to execute 'insertBefore' on 'Node' #2

Closed mutil closed 3 years ago

mutil commented 3 years ago

Steps to reproduce:

  1. git clone https://github.com/qnipp/meteor-svelte-tracker-ssr-example
  2. cd meteor-svelte-tracker-ssr-example; meteor update Some warnings at this point, install suggested dependencies:
  3. meteor npm install --save svelte@3.27.0 @babel/runtime Working with full reload needed. Now trying to get HRM to work:
  4. meteor add hot-module-replacement Still makes a reload. Adding this package:
  5. meteor add zodern:melte and swap svelte:compiler with zodern:melte in .meteor/packages.

Now when I make a change, an error is thrown in browser console:

zodern_melte.js [HMR][Svelte] Error during component init: <Person>
zodern_melte.js DOMException: Failed to execute 'insertBefore' on 'Node': The node before which the new node is to be inserted is not a child of this node.
zodern commented 3 years ago

Using HMR with SSR is fixed in zodern:melte@1.4.0.