-
-
Notifications
You must be signed in to change notification settings - Fork 8.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(v2): introduce docs slug in front matter (#2771)
* feat: docs pathname frontmatter (for #2697) * feat: docs pathname frontmatter (for #2697) * chore: comment typo * feat: add slug frontmatter for docs * test: add tests for versioned sites slugs * docs: document slug feature * test: fix tests and snapshots about doc slug feature * docs(v2): doc slug wording * Update website/docs/docs.md Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com> Co-authored-by: Alexey Pyltsyn <lex61rus@gmail.com>
- Loading branch information
Showing
10 changed files
with
71 additions
and
24 deletions.
There are no files selected for viewing
File renamed without changes.
5 changes: 5 additions & 0 deletions
5
...ugin-content-docs/src/__tests__/__fixtures__/bad-slug-site/docs/invalid-slug.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
slug: hello/super | ||
--- | ||
|
||
Lorem |
1 change: 1 addition & 0 deletions
1
...urus-plugin-content-docs/src/__tests__/__fixtures__/simple-site/docs/foo/baz.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
--- | ||
id: baz | ||
title: baz | ||
slug: bazSlug.html | ||
--- | ||
|
||
## Images | ||
|
3 changes: 3 additions & 0 deletions
3
...s-plugin-content-docs/src/__tests__/__fixtures__/versioned-site/docs/foo/bar.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
--- | ||
slug: barSlug | ||
--- | ||
This is `next` version of bar. |
3 changes: 3 additions & 0 deletions
3
...c/__tests__/__fixtures__/versioned-site/versioned_docs/version-1.0.0/foo/bar.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
--- | ||
slug: barSlug | ||
--- | ||
Bar `1.0.0` ! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters