Skip to content

output

Class info

Classes

Name Children Inherits
BuildOutput
mkdocs_mknodes.generator.output
Everything a build function produced, independent of the site engine.
    NavItem
    mkdocs_mknodes.generator.output
    An entry of the site navigation.
      Script
      mkdocs_mknodes.generator.output
      A JavaScript file to include in every page.
        SiteMetadata
        mkdocs_mknodes.generator.output
        Site-level metadata inferred from the project.

          šŸ›ˆ DocStrings

          Engine-neutral result of running a MkNodes build function.

          BuildOutput dataclass

          Everything a build function produced, independent of the site engine.

          Writers (see mkdocs_mknodes.writers) turn this into the input of a concrete static site generator.

          Parameters:

          Name Type Description Default
          pages dict[str, str]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          assets dict[str, str | bytes]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          nav list[NavItem]

          Built-in mutable sequence.

          If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

          <dynamic>
          markdown_extensions dict[str, dict[str, Any]]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          extra_css list[str]

          Built-in mutable sequence.

          If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

          <dynamic>
          extra_javascript list[Script]

          Built-in mutable sequence.

          If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

          <dynamic>
          templates dict[str, str]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          extra dict[str, Any]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          metadata SiteMetadata

          Site-level metadata inferred from the project.

          <dynamic>
          edit_paths dict[str, str]

          dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)

          <class 'dict'>
          Source code in mkdocs_mknodes/generator/output.py
          @dataclasses.dataclass
          class BuildOutput:
              """Everything a build function produced, independent of the site engine.
          
              Writers (see `mkdocs_mknodes.writers`) turn this into the input of a concrete
              static site generator.
              """
          
              pages: dict[str, str] = dataclasses.field(default_factory=dict)
              """Markdown pages: path relative to the docs root -> Markdown."""
              assets: dict[str, str | bytes] = dataclasses.field(default_factory=dict)
              """Static files: path relative to the docs root -> content (CSS, JS, images, ...)."""
              nav: list[NavItem] = dataclasses.field(default_factory=list)
              """Navigation tree."""
              markdown_extensions: dict[str, dict[str, Any]] = dataclasses.field(default_factory=dict)
              """Python-Markdown extensions required by the pages: name -> config."""
              extra_css: list[str] = dataclasses.field(default_factory=list)
              """Stylesheets: URLs or paths relative to the docs root (contained in `assets`)."""
              extra_javascript: list[Script] = dataclasses.field(default_factory=list)
              """Scripts: URLs or paths relative to the docs root (contained in `assets`)."""
              templates: dict[str, str] = dataclasses.field(default_factory=dict)
              """Theme template overrides (Material-style Jinja blocks): filename -> template."""
              extra: dict[str, Any] = dataclasses.field(default_factory=dict)
              """Theme variables (`extra` in MkDocs / Zensical configs)."""
              metadata: SiteMetadata = dataclasses.field(default_factory=SiteMetadata)
              """Site metadata inferred from the project."""
              edit_paths: dict[str, str] = dataclasses.field(default_factory=dict)
              """Page path -> repository path of the source that generated it."""
          
              @property
              def files(self) -> dict[str, str | bytes]:
                  """Pages and assets combined."""
                  return {**self.assets, **self.pages}
          

          assets class-attribute instance-attribute

          assets: dict[str, str | bytes] = dataclasses.field(default_factory=dict)
          

          Static files: path relative to the docs root -> content (CSS, JS, images, ...).

          edit_paths class-attribute instance-attribute

          edit_paths: dict[str, str] = dataclasses.field(default_factory=dict)
          

          Page path -> repository path of the source that generated it.

          extra class-attribute instance-attribute

          extra: dict[str, Any] = dataclasses.field(default_factory=dict)
          

          Theme variables (extra in MkDocs / Zensical configs).

          extra_css class-attribute instance-attribute

          extra_css: list[str] = dataclasses.field(default_factory=list)
          

          Stylesheets: URLs or paths relative to the docs root (contained in assets).

          extra_javascript class-attribute instance-attribute

          extra_javascript: list[Script] = dataclasses.field(default_factory=list)
          

          Scripts: URLs or paths relative to the docs root (contained in assets).

          files property

          files: dict[str, str | bytes]
          

          Pages and assets combined.

          markdown_extensions class-attribute instance-attribute

          markdown_extensions: dict[str, dict[str, Any]] = dataclasses.field(default_factory=dict)
          

          Python-Markdown extensions required by the pages: name -> config.

          metadata class-attribute instance-attribute

          metadata: SiteMetadata = dataclasses.field(default_factory=SiteMetadata)
          

          Site metadata inferred from the project.

          nav class-attribute instance-attribute

          nav: list[NavItem] = dataclasses.field(default_factory=list)
          

          Navigation tree.

          pages class-attribute instance-attribute

          pages: dict[str, str] = dataclasses.field(default_factory=dict)
          

          Markdown pages: path relative to the docs root -> Markdown.

          templates class-attribute instance-attribute

          templates: dict[str, str] = dataclasses.field(default_factory=dict)
          

          Theme template overrides (Material-style Jinja blocks): filename -> template.

          NavItem dataclass

          An entry of the site navigation.

          Either a link to a page / URL (target set) or a section (children set).

          Parameters:

          Name Type Description Default
          title str
          required
          target str | None

          Page path (relative to the docs root) or an external URL.

          None
          children list[NavItem]

          Built-in mutable sequence.

          If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

          <dynamic>
          Source code in mkdocs_mknodes/generator/output.py
          @dataclasses.dataclass
          class NavItem:
              """An entry of the site navigation.
          
              Either a link to a page / URL (`target` set) or a section (`children` set).
              """
          
              title: str
              target: str | None = None
              """Page path (relative to the docs root) or an external URL."""
              children: list[NavItem] = dataclasses.field(default_factory=list)
          
              @property
              def is_section(self) -> bool:
                  return self.target is None
          
              def iter_targets(self):
                  if self.target:
                      yield self.target
                  for child in self.children:
                      yield from child.iter_targets()
          

          target class-attribute instance-attribute

          target: str | None = None
          

          Page path (relative to the docs root) or an external URL.

          Script dataclass

          A JavaScript file to include in every page.

          Parameters:

          Name Type Description Default
          path str

          URL or path relative to the docs root.

          required
          defer bool
          False
          async_ bool
          False
          typ str | None
          None
          Source code in mkdocs_mknodes/generator/output.py
          @dataclasses.dataclass
          class Script:
              """A JavaScript file to include in every page."""
          
              path: str
              """URL or path relative to the docs root."""
              defer: bool = False
              async_: bool = False
              typ: str | None = None
          

          path instance-attribute

          path: str
          

          URL or path relative to the docs root.

          SiteMetadata dataclass

          Site-level metadata inferred from the project.

          Parameters:

          Name Type Description Default
          site_name str | None
          None
          site_description str | None
          None
          site_author str | None
          None
          repo_url str | None
          None
          copyright str | None
          None
          social list[dict[str, str]]

          Built-in mutable sequence.

          If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

          <dynamic>
          Source code in mkdocs_mknodes/generator/output.py
          @dataclasses.dataclass
          class SiteMetadata:
              """Site-level metadata inferred from the project."""
          
              site_name: str | None = None
              site_description: str | None = None
              site_author: str | None = None
              repo_url: str | None = None
              copyright: str | None = None
              social: list[dict[str, str]] = dataclasses.field(default_factory=list)
          
          Page info
          Resources
          Resources(css=[],
                    markdown_extensions={'tables': {}},
                    plugins=[Plugin('mkdocstrings')],
                    js=[],
                    assets=[],
                    packages=[])
          
          Metadata
          created:
            source_filename: /home/runner/work/mkdocs-mknodes/mkdocs-mknodes/.venv/lib/python3.13/site-packages/mknodes/pages/mkmodulepage/__init__.py
            source_function: MkModulePage.__init__
            source_line_no: 52
          title: output