🐛 The bug
When the pixel / tag id is set only via runtimeConfig.public.scripts and/or NUXT_PUBLIC_SCRIPTS_* (no id in scripts.registry), the dev server can still log:
[nuxt-scripts] registry.<key>: missing required field 'id'. The script infrastructure is registered but will not function without it.
By then runtimeConfig.public.scripts already has id after the module merge, so the warning is wrong and clashes with the documented env / runtimeConfig flow.
Docs: Nuxt Config — Environment Variables
🛠️ To reproduce
https://stackblitz.com/edit/github-gzbuzr-ghdbaa84?file=app%2Fapp.vue,app%2Fpages%2Findex.vue,nuxt.config.ts,package.json
🌈 Expected behavior
No WARN when the effective config (after merging process.env / registryWithDefaults into runtimeConfig.public.scripts) satisfies the schema’s required fields.
If id is truly missing everywhere, the WARN should still appear.
ℹ️ Additional context
No response
🐛 The bug
When the pixel / tag id is set only via runtimeConfig.public.scripts and/or NUXT_PUBLIC_SCRIPTS_* (no id in scripts.registry), the dev server can still log:
By then runtimeConfig.public.scripts already has id after the module merge, so the warning is wrong and clashes with the documented env / runtimeConfig flow.
Docs: Nuxt Config — Environment Variables
🛠️ To reproduce
https://stackblitz.com/edit/github-gzbuzr-ghdbaa84?file=app%2Fapp.vue,app%2Fpages%2Findex.vue,nuxt.config.ts,package.json
🌈 Expected behavior
No WARN when the effective config (after merging process.env / registryWithDefaults into runtimeConfig.public.scripts) satisfies the schema’s required fields.
If id is truly missing everywhere, the WARN should still appear.
ℹ️ Additional context
No response