chore: do not fail the build if a localized site has a broken link (#9339)

This commit is contained in:
Sébastien Lorber 2023-09-22 17:50:50 +02:00 committed by GitHub
parent 84b165c4f9
commit 46407ecc2d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -183,7 +183,11 @@ module.exports = async function createConfigAsync() {
return result;
},
},
onBrokenLinks: 'throw',
onBrokenLinks:
// Do not fail the build if a localized site has a broken link
process.env.DOCUSAURUS_CURRENT_LOCALE === defaultLocale
? 'throw'
: 'warn',
onBrokenMarkdownLinks: 'warn',
favicon: 'img/docusaurus.ico',
customFields: {