Skip to content

Options

You can customize the plugin by setting options in mkdocs.yml. For example:

plugins:
  - charts:
      vega_width: container
      vega_theme: default
      vega_theme_dark: dark
      vega_renderer: svg
      use_data_path: True
      data_path: ""
  • vega_width (default is container). When not specified explicitly in the JSON schema, the width to use (see vegalite customizing size). When set to container width will be 100%.
  • vega_theme (default is default). Specify one of the available vegalite themes.
  • vega_theme_dark (default is dark). When using the mkdocs-material theme with a dark mode, automatically render charts using this theme. Dark mode toggle is also supported. Specify one of the available vegalite themes.
  • vega_renderer (default is svg). Specify one of the available vegalite renderers.
  • use_data_path (default is True). When True, any relative urls used in the JSON schema are relative to the data_path. When False, relative urls should be relative to the URL of the page.
  • data_path (default is ""). When use_data_path is enabled, the base path relative to the docs/ folder.

Last update: 2023-09-25
Created: 2021-12-08