Open remihuigen opened 1 month ago
UPDATE: Just noticed that as soon as I remove @nuxt/scripts
from the target apps devDependencies (which should be fine, since it's installed as a dependency of the layer), the duplicated imports warnings occur in the target app as well...
i'm actually getting this without using layers:
[4:15:11 PM] WARN Duplicated imports "useScriptGoogleMaps", the one from "#app/composables/script-stubs" has been ignored and "/Users/larry/Development/test/app-debug/node_modules/.pnpm/@nuxt+scripts@0.9.5_@capacitor+preferences@6.0.2_@capacitor+core@6.1.2__@nuxt+devtools@_cbcf2370854887da015adfb8b52a6431/node_modules/@nuxt/scripts/dist/runtime/registry/google-maps" is used
[4:15:11 PM] WARN Duplicated imports "useScriptCrisp", the one from "#app/composables/script-stubs" has been ignored and "/Users/larry/Development/test/app-debug/node_modules/.pnpm/@nuxt+scripts@0.9.5_@capacitor+preferences@6.0.2_@capacitor+core@6.1.2__@nuxt+devtools@_cbcf2370854887da015adfb8b52a6431/node_modules/@nuxt/scripts/dist/runtime/registry/crisp" is used
🐛 The bug
Getting a whole bunch of duplicated imports from nuxt/scripts when running
nuxi dev .playground
.A target app that's using this layer, shows no logs of duplicated imports. So this only happens when running a playground.
Attached a reproduction containing an empty nuxt layer, with only Nuxt Scripts installed as a module.
🛠️ To reproduce
https://stackblitz.com/github/onderwijsin/onderwijsloket-common?file=README.md
🌈 Expected behavior
No duplicated imports :)
ℹ️ Additional context