Migration
Nuxt 4 is required. The module no longer supports Nuxt 3. Nothing else in your configuration changes on that account.
A tag ID named twice is configured once. If the same ID appeared in both the id option and the tags array, both entries used to reach the config command, and the second overwrote the first. Only one survives now, and it is the id entry, which carries the top-level initCommands and config. Move any settings you kept in the duplicate tags entry up to the top level, or drop the id option and keep the entry in tags.
An existing dataLayer no longer stops initialization. initialize() used to do nothing at all when window.dataLayer was already present, which a third-party snippet such as Google Tag Manager creates before Nuxt hydrates. The module tracks the IDs it configured itself instead, so it now configures its tags alongside such a snippet rather than silently standing down. If you relied on the old behavior to let GTM own the page, stop calling initialize() – or set enabled to false.
🚨 Breaking Changes
- Require Nuxt 4 - by @johannschopplich (f9d2e)
🐞 Bug Fixes
- Accept a mixed array of tag IDs and tag objects - by @johannschopplich (38562)
- Configure a tag ID that initialize receives at runtime - by @johannschopplich (23694)
- Configure each tag ID exactly once - by @johannschopplich (92aab)
- Track configured tag IDs instead of inferring them from dataLayer - by @johannschopplich (c3bd0)