Skip to content

Commit c71ac9b

Browse files
committed
⬆️ UPGRADE: Replace mdformat-frontmatter with mdformat-frontmatter (#46)
Closes #45
1 parent 6e707b8 commit c71ac9b

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

mdformat_myst/plugin.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ def update_mdit(mdit: MarkdownIt) -> None:
2323
mdit.options["parser_extension"].append(tables_plugin)
2424
tables_plugin.update_mdit(mdit)
2525

26-
# Enable mdformat-frontmatter plugin
27-
frontmatter_plugin = mdformat.plugins.PARSER_EXTENSIONS["frontmatter"]
28-
if frontmatter_plugin not in mdit.options["parser_extension"]:
29-
mdit.options["parser_extension"].append(frontmatter_plugin)
30-
frontmatter_plugin.update_mdit(mdit)
26+
# Enable mdformat-front-matters plugin
27+
front_matters_plugin = mdformat.plugins.PARSER_EXTENSIONS["front_matters"]
28+
if front_matters_plugin not in mdit.options["parser_extension"]:
29+
mdit.options["parser_extension"].append(front_matters_plugin)
30+
front_matters_plugin.update_mdit(mdit)
3131

3232
# Enable mdformat-footnote plugin
3333
footnote_plugin = mdformat.plugins.PARSER_EXTENSIONS["footnote"]

tests/data/fixtures.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,8 @@ firstname: Dorothy
299299
Thats YAML front matter^
300300
.
301301
---
302-
lastname: Blorothy
303302
firstname: Dorothy
303+
lastname: Blorothy
304304
---
305305
306306
Thats YAML front matter^

0 commit comments

Comments
 (0)