mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-13 00:57:53 +02:00
refactor: enforce named capture groups; clean up regexes (#6524)
* refactor: enforce named capture groups; clean up regexes * fixes * fix
This commit is contained in:
parent
c56e6194b4
commit
1cefb643dd
32 changed files with 80 additions and 77 deletions
|
@ -36,7 +36,7 @@ const sidebarItemAutogeneratedSchema =
|
|||
type: 'autogenerated',
|
||||
dirName: Joi.string()
|
||||
.required()
|
||||
.pattern(/^[^/](.*[^/])?$/)
|
||||
.pattern(/^[^/](?:.*[^/])?$/)
|
||||
.message(
|
||||
'"dirName" must be a dir path relative to the docs folder root, and should not start or end with slash',
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue