Refactor to move reparse of micromark htmlFlow token content into core micromarkParse implementation for simplicity and sharing.

This commit is contained in:
David Anson 2023-07-21 22:49:08 -07:00
parent 9646590496
commit e86fb7699d
11 changed files with 307 additions and 84 deletions

View file

@ -3,10 +3,10 @@
"use strict";
const micromark = require("./micromark.cjs");
const { newLineRe } = require("./shared.js");
// Regular expression for matching common newline characters
// See NEWLINES_RE in markdown-it/lib/rules_core/normalize.js
const newLineRe = /\r\n?|\n/g;
module.exports.newLineRe = newLineRe;
// Regular expression for matching common front matter (YAML and TOML)