Trigger recompilation of an NPM package by an Atmosphere package

As written in the guide and stated in a number of forum posts, NPM packages are not recompiled for legacy browser.

In my case, the problem arose using the svelte NPM together with svelte:compiler. I’ve documented the issue here.

There are two solutions, one of them must be done by the developer, who uses this NPM:

  1. Create a symbolic link in the imports directory, which points to the package in the node_modules directory (as described here)
  2. Use the meteor.nodeModules.recompile option in package.json (described here, didn’t work in my case)

To be more developer-friendly, it would be nice to trigger the recompilation in the Atmosphere package.

Is there already a way to do this?

1 Like