Skip to content

Add JSON schema for mkdocs-awesome-nav external plugin#8341

Merged
squidfunk merged 5 commits intosquidfunk:masterfrom
bybatkhuu:master
Jul 29, 2025
Merged

Add JSON schema for mkdocs-awesome-nav external plugin#8341
squidfunk merged 5 commits intosquidfunk:masterfrom
bybatkhuu:master

Conversation

@bybatkhuu
Copy link
Copy Markdown
Contributor

@bybatkhuu bybatkhuu commented Jul 18, 2025

This pull request introduces a new JSON schema file to define the configuration for advanced navigation in MkDocs using external YAML files. The schema provides validation and documentation for the awesome-nav plugin.

New feature: JSON schema for awesome-nav plugin

  • docs/schema/plugins/external/awesome-nav.json: Added a JSON schema to support the awesome-nav plugin configuration. The schema includes options for specifying a YAML file (filename) that defines the navigation structure, with a default value of .nav.yml. It also provides links to relevant documentation for better usability.

PR reason

  • VS Code linting as an error on awesome-nav plugin that is inside mkdcos.yml file, which is annoying:

Screenshot 2025-07-18 at 15 45 41

Can you help me fix this?

@squidfunk
Copy link
Copy Markdown
Owner

It needs to be added to the list of external plugins:

"external": {
"description": "External plugins, schema provided by us",
"anyOf": [
{
"$ref": "plugins/external/gen-files.json"
},
{
"$ref": "plugins/external/git-authors.json"
},
{
"$ref": "plugins/external/git-committers.json"
},
{
"$ref": "plugins/external/git-revision-date.json"
},
{
"$ref": "plugins/external/literate-nav.json"
},
{
"$ref": "plugins/external/macros.json"
},
{
"$ref": "plugins/external/minify.json"
},
{
"$ref": "plugins/external/redirects.json"
},
{
"$ref": "plugins/external/section-index.json"
}
]
},

@bybatkhuu
Copy link
Copy Markdown
Contributor Author

bybatkhuu commented Jul 23, 2025

@squidfunk, as you said,
I just updated, can you check it?

mkdocs-material/docs/schema/plugins.json

Thank you for your feedback :)

BTW, I'm not a maintainer of that awesome-nav plugin; I'm just using mkdocs-material and awesome-nav plugin together always.

Your works are awesome! :D

Copy link
Copy Markdown
Owner

@squidfunk squidfunk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Almost there!

@squidfunk
Copy link
Copy Markdown
Owner

Thanks! LGTM.

@squidfunk squidfunk merged commit 9d95854 into squidfunk:master Jul 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants