MODULE

MKAPI.PLUGINS.MKDOCS

This module provides the MkapiPlugin class.

MkapiPlugin is a MkDocs plugin that creates Python API documentation from Docstring.

Classes
class

mkapi.plugins.mkdocs.MkapiPlugin()

Bases
mkdocs.plugins.BasePlugin

MkapiPlugin class for API generation.

Attributes
  • __class__.server
  • abs_api_paths
  • config
  • pages
Methods
  • load_config(options, config_file_path) Load config from a dict of options. Returns a tuple of (errors, warnings).</>
  • on_config(config, **kwargs) Inserts src_dirs to sys.path.</>
  • on_files(files, config, **kwargs) Collects plugin CSS ans JavaScript and appends them to files.</>
  • on_page_content(html, page, config, files, **kwargs) Merges html and MkApi's node structure.</>
  • on_page_markdown(markdown, page, config, files, **kwargs) Converts Markdown source to intermidiate version.</>
method

load_config(options, config_file_path=None)

Load config from a dict of options. Returns a tuple of (errors, warnings).

Parameters
  • options
  • config_file_path (optional)
method

on_config(config, **kwargs)

Inserts src_dirs to sys.path.

Parameters
  • config
  • **kwargs
method

on_files(files, config, **kwargs)

Collects plugin CSS ans JavaScript and appends them to files.

Parameters
  • files
  • config
  • **kwargs
method

on_page_markdown(markdown, page, config, files, **kwargs)

Converts Markdown source to intermidiate version.

Parameters
  • markdown
  • page
  • config
  • files
  • **kwargs
method

on_page_content(html, page, config, files, **kwargs)

Merges html and MkApi's node structure.

Parameters
  • html
  • page
  • config
  • files
  • **kwargs