mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-18 03:26:57 +02:00
chore: add cSpell for spell checking (#6456)
* chore: Add cSpell for spell checking * chore: exclude map files and remove dups * chore: exclude more binary files * chore: remove MD headings * Update .cspell.json * fix a few spellings * fix more * fix Signed-off-by: Joshua Chen <sidachen2003@gmail.com> * fix a few * oops Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
This commit is contained in:
parent
a41a5c328c
commit
521eb119a7
64 changed files with 852 additions and 142 deletions
packages/docusaurus-plugin-content-docs/src
|
@ -138,7 +138,7 @@ function doProcessDocMetadata({
|
|||
custom_edit_url: customEditURL,
|
||||
|
||||
// Strip number prefixes by default (01-MyFolder/01-MyDoc.md => MyFolder/MyDoc) by default,
|
||||
// but allow to disable this behavior with frontmatter
|
||||
// but allow to disable this behavior with front matter
|
||||
parse_number_prefixes: parseNumberPrefixes = true,
|
||||
} = frontMatter;
|
||||
|
||||
|
@ -162,7 +162,7 @@ function doProcessDocMetadata({
|
|||
throw new Error(`Document id "${baseID}" cannot include slash.`);
|
||||
}
|
||||
|
||||
// For autogenerated sidebars, sidebar position can come from filename number prefix or frontmatter
|
||||
// For autogenerated sidebars, sidebar position can come from filename number prefix or front matter
|
||||
const sidebarPosition: number | undefined =
|
||||
frontMatter.sidebar_position ?? numberPrefix;
|
||||
|
||||
|
@ -175,7 +175,7 @@ function doProcessDocMetadata({
|
|||
: `version-${versionMetadata.versionName}`;
|
||||
|
||||
// TODO legacy retrocompatibility
|
||||
// I think it's bad to affect the frontmatter id with the dirname?
|
||||
// I think it's bad to affect the front matter id with the dirname?
|
||||
function computeDirNameIdPrefix() {
|
||||
if (sourceDirName === '.') {
|
||||
return undefined;
|
||||
|
@ -198,7 +198,7 @@ function doProcessDocMetadata({
|
|||
baseID,
|
||||
source,
|
||||
sourceDirName,
|
||||
frontmatterSlug: frontMatter.slug,
|
||||
frontMatterSlug: frontMatter.slug,
|
||||
stripDirNumberPrefixes: parseNumberPrefixes,
|
||||
numberPrefixParser: options.numberPrefixParser,
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue