A MkDocs plugin that injects the mkdocs.yml extra variables into the markdown template, also supporting external data files via jinja2 templating. Current version 0.2.6, requires Python >=3.6, maintained with sporadic releases.
pip install mkdocs-markdownextradata-pluginVerified import paths — ran on the pinned version, not inferred.
Enable the plugin in mkdocs.yml. Create a `_data` folder with YAML/JSON files (e.g., `_data/mydata.yaml`). Reference variables as `{{ mydata_key }}` in markdown.
Set `priority` in mkdocs.yml plugin config (e.g., priority: 50) or use `plugins: { markdownextradata: { ... }, search: { ... } }` with explicit order.For `_data/team.yaml` with key `members`, use `{{ team.members }}` not `{{ extra.team.members }}`.Upgrade to >=0.2.4 or rename files to not start with a digit.