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 build script error of docs site #934

Merged
merged 1 commit into from
Mar 22, 2021

Conversation

mondaychen
Copy link
Contributor

Got this message from yarn build

error building locale=en
Error: Plugin docusaurus-plugin-google-analytics is used 2 times with id=default.
To use the same plugin multiple times on a Docusaurus site, you need to assign a unique id to each plugin instance.
    at /Users/mengdi/workspace/github/Recoil/docs/node_modules/@docusaurus/core/lib/server/plugins/pluginIds.js:20:23

We didn't have this before -- might be a result of upgrading docusaurus in #932

According to facebook/docusaurus#3632 (comment)

If you use the classic preset with googleAnalytics themeConfig, you already use the google analytics plugin, as it's included in the preset.
we should remove the GA plugin from our config file to resolve this.
After removing this line, the build is successful, and we can still find GA script in index.html output.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Mar 22, 2021
@mondaychen mondaychen changed the title fix build script error fix build script error of docs site Mar 22, 2021
@mondaychen mondaychen merged commit e470024 into facebookexperimental:docs Mar 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build / infra CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants