brk-code

mkdocs の API リファレンス

mkdocs (mkdocs/mkdocs) の公開 API 103 件 —— クラス 38、関数 29、メソッド 36。実際のソースを静的解析して抽出した正確なシグネチャを掲載しています。

リポジトリ: mkdocs/mkdocs

種別件数
クラス38
関数29
メソッド36

API 一覧

classmkdocs.__main__.State
Maintain logging level.
funcmkdocs.__main__.build_command(clean, **kwargs)
Build the MkDocs documentation.
funcmkdocs.__main__.cli()
MkDocs - Project documentation with Markdown.
funcmkdocs.__main__.new_command(project_directory)
Create a new MkDocs project.
funcmkdocs.__main__.serve_command(**kwargs)
Run the builtin development server.
funcmkdocs.commands.build.build(config:MkDocsConfig, *serve_url:str | None=None, *dirty:bool=False) -> None
Perform a full site build.
funcmkdocs.commands.serve.serve(config_file:str | None=None, livereload:bool=True, build_type:str | None=None, watch_theme:bool=False, watch:list[str]=[], *open_in_browser:bool=False, **kwargs) -> None
Start the MkDocs development server.
methodmkdocs.config.base.Config.load_dict(patch:dict) -> None
Load config options from a dictionary.
methodmkdocs.config.base.Config.load_file(config_file:IO) -> None
Load config options from the open file descriptor of a YAML file.
classmkdocs.config.base.ValidationError
Raised during the validation process of the config on errors.
funcmkdocs.config.base.load_config(config_file:str | IO | None=None, *config_file_path:str | None=None, **kwargs) -> MkDocsConfig
Load the configuration for a given file object or name.
classmkdocs.config.config_options.Choice
Choice Config Option.
classmkdocs.config.config_options.Deprecated
Deprecated Config Option.
classmkdocs.config.config_options.DictOfItems
Validates a dict of items.
classmkdocs.config.config_options.Dir
Dir Config Option.
classmkdocs.config.config_options.ExtraScriptValue
An extra script to be added to the page.
classmkdocs.config.config_options.File
File Config Option.
classmkdocs.config.config_options.FilesystemObject
Base class for options that point to filesystem objects.
classmkdocs.config.config_options.IpAddress
IpAddress Config Option.
classmkdocs.config.config_options.ListOfItems
Validates a homogeneous list of items.
classmkdocs.config.config_options.ListOfPaths
List of Paths Config Option.
classmkdocs.config.config_options.MarkdownExtensions
Markdown Extensions Config Option.
classmkdocs.config.config_options.Nav
Nav Config Option.
classmkdocs.config.config_options.OptionallyRequired
Soft-deprecated, do not use.
methodmkdocs.config.config_options.OptionallyRequired.validate(value)
Perform some initial validation.
classmkdocs.config.config_options.PathSpec
A path pattern based on gitignore-like syntax.
classmkdocs.config.config_options.Plugins
Plugins config option.
classmkdocs.config.config_options.Private
A config option that can only be populated programmatically.
classmkdocs.config.config_options.SiteDir
SiteDir Config Option.
classmkdocs.config.config_options.SubConfig
Subconfig Config Option.
classmkdocs.config.config_options.Theme
Theme Config Option.
classmkdocs.config.config_options.Type
Type Config Option.
classmkdocs.config.config_options.URL
URL Config Option.
funcmkdocs.config.defaults.get_schema() -> base.PlainConfigSchema
Soft-deprecated, do not use.
classmkdocs.contrib.search.LangOption
Validate Language(s) provided in config are known languages.
classmkdocs.contrib.search.SearchPlugin
Add a search feature to MkDocs.
methodmkdocs.contrib.search.SearchPlugin.on_config(config:MkDocsConfig, **kwargs) -> MkDocsConfig
Add plugin templates and scripts to config.
methodmkdocs.contrib.search.SearchPlugin.on_page_context(context:TemplateContext, page:Page, **kwargs) -> None
Add page to search index.
methodmkdocs.contrib.search.SearchPlugin.on_post_build(config:MkDocsConfig, **kwargs) -> None
Build search index.
methodmkdocs.contrib.search.SearchPlugin.on_pre_build(config:MkDocsConfig, **kwargs) -> None
Create search index instance for later use.
classmkdocs.exceptions.Abort
Abort the build.
classmkdocs.exceptions.BuildError
This error may be raised by MkDocs during the build process.
classmkdocs.exceptions.MkDocsException
The base class which all MkDocs exceptions inherit from.
classmkdocs.plugins.BasePlugin
Plugin base class.
methodmkdocs.plugins.BasePlugin.load_config(options:dict[str, Any], config_file_path:str | None=None) -> tuple[ConfigErrors, ConfigWarnings]
Load config from a dict of options.
methodmkdocs.plugins.BasePlugin.on_post_build(*config:MkDocsConfig) -> None
The `post_build` event does not alter any variables.
methodmkdocs.plugins.BasePlugin.on_pre_build(*config:MkDocsConfig) -> None
The `pre_build` event does not alter any variables.
classmkdocs.plugins.PluginCollection
A collection of plugins.
classmkdocs.plugins.PrefixedLogger
A logger adapter to prefix log messages.
methodmkdocs.plugins.PrefixedLogger.process(msg:str, kwargs:MutableMapping[str, Any]) -> tuple[str, Any]
Process the message.
funcmkdocs.plugins.event_priority(priority:float) -> Callable[[T], T]
A decorator to set an event priority for an event handler method.
funcmkdocs.plugins.get_plugin_logger(name:str) -> PrefixedLogger
Return a logger for plugins.
classmkdocs.structure.files.File
A MkDocs File object.
methodmkdocs.structure.files.File.abs_dest_path() -> str
The absolute concrete path of the destination file.
methodmkdocs.structure.files.File.abs_src_path() -> str | None
The absolute concrete path of the source file.
methodmkdocs.structure.files.File.content_bytes() -> bytes
Get the content of this file as a bytestring.
methodmkdocs.structure.files.File.content_string() -> str
Get the content of this file as a string.
methodmkdocs.structure.files.File.copy_file(dirty:bool=False) -> None
Copy source file to destination, ensuring parent directories exist.
methodmkdocs.structure.files.File.is_css() -> bool
Return True if file is a CSS file.
methodmkdocs.structure.files.File.is_documentation_page() -> bool
Return True if file is a Markdown page.
methodmkdocs.structure.files.File.is_javascript() -> bool
Return True if file is a JavaScript file.
methodmkdocs.structure.files.File.is_media_file() -> bool
Return True if file is not a documentation or static page.
methodmkdocs.structure.files.File.is_static_page() -> bool
Return True if file is a static page (HTML, XML, JSON).
methodmkdocs.structure.files.File.url_relative_to(other:File | str) -> str
Return url for file relative to other file.
classmkdocs.structure.files.Files
A collection of [File][mkdocs.structure.files.File] objects.
methodmkdocs.structure.files.Files.append(file:File) -> None
Add file to the Files collection.
methodmkdocs.structure.files.Files.copy_static_files(dirty:bool=False, *inclusion:Callable[[InclusionLevel], bool]=InclusionLevel.is_included) -> None
Copy static files from source to destination.
methodmkdocs.structure.files.Files.css_files() -> Sequence[File]
Return iterable of all CSS file objects.
methodmkdocs.structure.files.Files.documentation_pages(*inclusion:Callable[[InclusionLevel], bool]=InclusionLevel.is_included) -> Sequence[File]
Return iterable of all Markdown page file objects.
methodmkdocs.structure.files.Files.get_file_from_path(path:str) -> File | None
Return a File instance with File.src_uri equal to path.
methodmkdocs.structure.files.Files.javascript_files() -> Sequence[File]
Return iterable of all javascript file objects.
methodmkdocs.structure.files.Files.remove(file:File) -> None
Remove file from Files collection.
methodmkdocs.structure.files.Files.src_paths() -> dict[str, File]
Soft-deprecated, prefer `src_uris`.
methodmkdocs.structure.files.Files.static_pages() -> Sequence[File]
Return iterable of all static page file objects.
funcmkdocs.structure.files.get_files(config:MkDocsConfig) -> Files
Walk the `docs_dir` and return a Files collection.
funcmkdocs.structure.nav.get_navigation(files:Files, config:MkDocsConfig) -> Navigation
Build site navigation from config and files.
methodmkdocs.structure.pages.Page.render(config:MkDocsConfig, files:Files) -> None
Convert the Markdown source file to HTML as per the config.
methodmkdocs.structure.pages.Page.title() -> str | None
Returns the title for the current page.
methodmkdocs.structure.pages.Page.url() -> str
The URL of the page relative to the MkDocs `site_dir`.
classmkdocs.structure.toc.AnchorLink
A single entry in the table of contents.
methodmkdocs.structure.toc.AnchorLink.url() -> str
The hash fragment of a URL pointing to the item.
classmkdocs.structure.toc.TableOfContents
Represents the table of contents for a given page.
classmkdocs.theme.Theme
A Theme object.
methodmkdocs.theme.Theme.get_env() -> jinja2.Environment
Return a Jinja environment for the theme.
classmkdocs.utils.CountHandler
Counts all logged messages >= level.
classmkdocs.utils.DuplicateFilter
Avoid logging duplicate messages.
funcmkdocs.utils.create_media_urls(path_list:Iterable[str], page:Page | None=None, base:str='') -> list[str]
Soft-deprecated, do not use.
funcmkdocs.utils.dirname_to_title(dirname:str) -> str
Return a page tile obtained from a directory name.
funcmkdocs.utils.get_build_date() -> str
Returns the displayable date string.
funcmkdocs.utils.get_build_datetime() -> datetime
Returns an aware datetime object.
funcmkdocs.utils.get_markdown_title(markdown_src:str) -> str | None
Soft-deprecated, do not use.
funcmkdocs.utils.get_relative_url(url:str, other:str) -> str
Return given url relative to other.
funcmkdocs.utils.get_theme_dir(name:str) -> str
Return the directory of an installed theme by name.
funcmkdocs.utils.get_theme_names() -> Collection[str]
Return a list of all installed themes by name.
funcmkdocs.utils.get_themes() -> dict[str, EntryPoint]
Return a dict of all installed themes as {name: EntryPoint}.
funcmkdocs.utils.is_error_template(path:str) -> bool
Return True if the given file path is an HTTP error template.
funcmkdocs.utils.is_markdown_file(path:str) -> bool
Return True if the given file path is a Markdown file.
funcmkdocs.utils.meta.get_data(doc:str) -> tuple[str, dict[str, Any]]
Extract meta-data from a text document.
funcmkdocs.utils.normalize_url(path:str, page:Page | None=None, base:str='') -> str
Return a URL relative to the given page or using the base.
funcmkdocs.utils.reduce_list(data_set:Iterable[T]) -> list[T]
Reduce duplicate items in a list and preserve order.
funcmkdocs.utils.templates.script_tag_filter(context:TemplateContext, extra_script:ExtraScriptValue) -> str
Converts an ExtraScript value to an HTML <script> tag line.
funcmkdocs.utils.templates.url_filter(context:TemplateContext, value:str) -> str
A Template filter to normalize URLs.
funcmkdocs.utils.write_file(content:bytes, output_path:str) -> None
Write content to output_path, making sure any parent directories exist.

この情報について

掲載しているシグネチャは mkdocs/mkdocs の公開ソースコードを Python の ast モジュールで静的解析し、引数名・デフォルト値・ 型注釈・戻り値型をそのまま抽出したものです。実装コードは保存していません。 詳しくは仕組みの解説をご覧ください。

収録ライブラリ一覧(全 805 件)へ戻る