mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-25 23:17:06 +02:00
feat: throw error if there is wrong field on siteConfig.js
This commit is contained in:
parent
ef17da741a
commit
9965eec798
4 changed files with 41 additions and 4 deletions
|
@ -3,7 +3,7 @@ const chalk = require('chalk');
|
|||
const escapeHtml = require('escape-html');
|
||||
|
||||
export default (str, rawLang) => {
|
||||
if (rawLang === 'text') {
|
||||
if (rawLang === 'text' || !rawLang) {
|
||||
return escapeHtml(str);
|
||||
}
|
||||
const lang = rawLang.toLowerCase();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue