Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(preset-classic): install the right plugin for googleTagManager #8597

Merged
merged 1 commit into from Feb 1, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 5 additions & 2 deletions packages/docusaurus-preset-classic/src/index.ts
Expand Up @@ -83,7 +83,10 @@ export default function preset(
}
if (googleTagManager) {
plugins.push(
makePluginConfig('@docusaurus/plugin-google-gtag', googleTagManager),
makePluginConfig(
'@docusaurus/plugin-google-tag-manager',
googleTagManager,
),
);
}
if (isProd && sitemap !== false) {
Expand All @@ -93,7 +96,7 @@ export default function preset(
throw new Error(
`Unrecognized keys ${Object.keys(rest).join(
', ',
)} found in preset-classic configuration. The allowed keys are debug, docs, blog, pages, sitemap, theme, googleAnalytics, gtag. Check the documentation: https://docusaurus.io/docs/using-plugins#docusauruspreset-classic for more information on how to configure individual plugins.`,
)} found in preset-classic configuration. The allowed keys are debug, docs, blog, pages, sitemap, theme, googleAnalytics, gtag, and googleTagManager. Check the documentation: https://docusaurus.io/docs/using-plugins#docusauruspreset-classic for more information on how to configure individual plugins.`,
);
}

Expand Down