1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-25 00:07:47 +01:00

docs: fix an issue where it goes into an infinite loop when building (#4596)

This change sets `noRuntimeDownloads` to `true` for
`plugin-remote-content'` to avoid the infinite loop issue mentioned in
https://github.com/rdilweb/docusaurus-plugin-remote-content/issues/51,
as described in

https://github.com/rdilweb/docusaurus-plugin-remote-content#noruntimedownloads.

It also updates some of the yarn scripts to generate the required files before `yarn start`, `yarn build`, and `yarn deploy`.

To manually generate the files, run:

```bash
yarn docusaurus download-remote-content-external
yarn docusaurus download-remote-content-sdks
```
This commit is contained in:
Thomas Heartman 2023-11-06 13:13:58 +01:00 committed by GitHub
parent f16ad4e899
commit edb15f5d00
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 3 deletions

View File

@ -714,6 +714,7 @@ module.exports = {
outDir: 'docs/generated', // the base directory to output to.
documents: sdks.urls, // the file names to download
modifyContent: sdks.modifyContent,
noRuntimeDownloads: true,
},
],
[
@ -725,6 +726,7 @@ module.exports = {
outDir: 'docs/generated/', // the base directory to output to.
documents: edgeAndProxy.urls, // the file names to download
modifyContent: edgeAndProxy.modifyContent,
noRuntimeDownloads: true,
},
],
],

View File

@ -7,11 +7,12 @@
},
"scripts": {
"docusaurus": "docusaurus",
"start": "docusaurus start",
"build": "yarn generate && docusaurus build",
"start": "yarn fetch-remote-content && docusaurus start",
"build": "yarn generate && yarn fetch-remote-content && docusaurus build",
"swizzle": "docusaurus swizzle",
"fetch-remote-content": "docusaurus download-remote-content-external && docusaurus download-remote-content-sdks",
"generate": "docusaurus gen-api-docs all && node clean-generated-docs.js",
"deploy": "yarn generate && docusaurus deploy",
"deploy": "yarn generate && yarn fetch-remote-content && docusaurus deploy",
"clear": "docusaurus clear",
"serve": "docusaurus serve",
"write-translations": "docusaurus write-translations",