mdformat icon indicating copy to clipboard operation
mdformat copied to clipboard

CommonMark compliant Markdown formatter

Results 84 mdformat issues
Sort by recently updated
recently updated
newest added

We use `mdformat` to validate Markdown formatting in a [documentation project](https://github.com/ByteInternet/hypernode-docs-next) we're running. Most users are contributing to the documentation by creating changes, commits and pull requests from the Github...

### Context The [plugins documentation](https://mdformat.readthedocs.io/en/stable/users/plugins.html) shows how to pass plugins to mdformat.text, but not how to do this using the Renderer API. At the moment I have `rendered = MDRenderer().render(tokens,...

enhancement

### Context In #263 we added support for `.mdformat.toml` as an on-disk configuration file. I would like to revisit the possibility of also reading fall-back configuration from `$XDG_CONFIG_HOME`. [platformdirs](https://pypi.org/project/platformdirs/) provides...

enhancement

PR adds an `exclude` option to the CLI (and to the configuration TOML) for excluding files matching the specified patterns. This provides a way to run `mdformat` outside of pre-commit...

### Describe the bug Running mdformat on ``` # X   x ``` (`# X\n\xa0\n\nx\n`, note the non-breaking space) results in the error message ``` The formatted Markdown renders to different...

bug

### Context Currently the formatter would change ``` - item A - item A.a - item B ``` as: ``` - item A - item A.a - item B ```...

invalid

### Context I created [this plugin](https://github.com/csala/mdformat-pyproject) that lets `mdformat` load options from a `[tool.mdformat]` section inside the `pyproject.toml` file, if it exists. This basically covers the need exposed in #356...

enhancement

### Context I am using `mdformat` but having troubles with the current thematic break rendering composed of 70 underscore characters, which I am rather used to typing as three dashes...

enhancement

### Context Currently, `mdformat` plugins are allowed to implement a `add_cli_options` function to add arguments to the `mdformat` `ArgumentParser`, but there is no way to allow those options to be...

enhancement

### Context `markdownlint` has rules for this: * [MD049](https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md#user-content-md049---emphasis-style-should-be-consistent) * [MD050](https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md#user-content-md050---strong-style-should-be-consistent) They seem like good rules and `mdformat` can do this. ### Proposal Pick a style for emphasis and strength,...

enhancement