fix(v2): script tags should allow unknown values (#3385)

https://github.com/facebook/docusaurus/issues/3378
This commit is contained in:
Sébastien Lorber 2020-09-01 19:40:37 +02:00 committed by GitHub
parent 5359d61d9e
commit 0d018a88c5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

View file

@ -42,6 +42,7 @@ describe('normalizeConfig', () => {
src: `/analytics.js`, src: `/analytics.js`,
async: true, async: true,
defer: true, defer: true,
'data-domain': 'xyz', // See https://github.com/facebook/docusaurus/issues/3378
}, },
], ],
stylesheets: [ stylesheets: [

View file

@ -77,7 +77,9 @@ const ConfigSchema = Joi.object({
src: Joi.string().required(), src: Joi.string().required(),
async: Joi.bool(), async: Joi.bool(),
defer: Joi.bool(), defer: Joi.bool(),
}), })
// See https://github.com/facebook/docusaurus/issues/3378
.unknown(),
), ),
stylesheets: Joi.array().items( stylesheets: Joi.array().items(
Joi.string(), Joi.string(),