Anyone else run into this issue with #SvelteKit where npm install my-module works but (e.g.) npm install ~/my-module throws a “require is not defined” error when my-module is a CommonJS module that has dependencies (and thus uses require)?

github.com/sveltejs/kit/issues

Not a huge deal but it should work and it makes developing a module harder than it needs to be as you can’t test it locally.

Wondering if there’s a magic configuration setting that works around the issue.

Follow

@aral what about using npm link for local dev/testing?

Sign in to participate in the conversation
Pixietown

Small server part of the pixie.town infrastructure. Registration is closed.