huang-julien / nuxt-applicationinsights

ApplicationInsights module for Nuxt 3.
15 stars 0 forks source link

ERROR [worker reload] [worker init] Cannot find module #15

Closed joe-mohan closed 5 months ago

joe-mohan commented 5 months ago

Hey, trying to install and check this out

nuxt: "^3.9.1"

after install and adding to modules, the project wont run or generate. First a warning:

WARN "/Users/joseph/Projects/xxxx/xxxx/xxxx/xxxx/node_modules/nuxt-applicationinsights/dist/runtime/server/plugins/setup.ts" is imported by "virtual:#internal/nitro/virtual/plugins", but could not be resolved – treating it as an external dependency.

Then an error:

ERROR Cannot find module '/Users/joseph/Projects/xxxx/xxxx/nuxt-applicationinsights/dist/runtime/server/plugins/setup.ts' imported from /Users/joseph/Projects/xxxx/xxxx/xxxx/xxxx/.nuxt/prerender/index.mjs

inspecting .nuxt/prerender/index.mjs shows:

...
import 'file:///Users/joseph/Projects/xxxx/xxxx/xxxx/xxxx/node_modules/unstorage/drivers/fs-lite.mjs';
import 'file:///Users/joseph/Projects/xxxx/xxxx/xxxx/xxxx/node_modules/radix3/dist/index.mjs';
import '../../../../nuxt-applicationinsights/dist/runtime/server/plugins/setup.ts';
import 'file:///Users/joseph/Projects/xxxx/xxxx/xxxx/xxxx/node_modules/nitro-applicationinsights/dist/index.mjs';

So that import path is incorrect, any ideas?

huang-julien commented 5 months ago

Thanks for your report :) !