feat(plugin-google-tag-manager): add new google-tag-manager plugin + deprecate google-analytics plugin #8470

This commit is contained in:
Lane Goolsby 2022-12-29 07:53:54 -08:00 committed by sebastienlorber
parent 704365c00b
commit 003729e9fe
14 changed files with 264 additions and 2 deletions

View file

@ -9,6 +9,16 @@ import APITable from '@site/src/components/APITable';
The default [Google Analytics](https://developers.google.com/analytics/devguides/collection/analyticsjs/) plugin. It is a JavaScript library for measuring how users interact with your website **in the production build**. If you are using Google Analytics 4 you might need to consider using [plugin-google-gtag](./plugin-google-gtag.md) instead.
:::danger Deprecated
This plugin is **deprecated**, and will become useless on July 1, 2023.
Google is [moving away from Universal Analytics](https://blog.google/products/marketingplatform/analytics/prepare-for-future-with-google-analytics-4/).
If you are still using this plugin with a `UA-*` tracking id, you should create a Google Analytics 4 account as soon as possible, and use [`@docusaurus/plugin-google-gtag`](./plugin-google-gtag.md) instead of this plugin. More details [here](https://github.com/facebook/docusaurus/issues/7221).
:::
:::caution production only
This plugin is always inactive in development and **only active in production** to avoid polluting the analytics statistics.