This is a remark-lint rule.
On some keyboards, for instance the default Swiss German keyboard layout
de_CH QWERTZ layout, the
# symbol is obtained using
alt-space inserts a non-breaking space, it seems easy to insert
#<non-breaking space> by mistake while writing Markdown heading
This leads to headings getting parsed as normal Markdown paragraphs, here
c are normal headings,
d have probably been typed too fast without releasing the
alt key between
remark-lint rule prevents this from ever happening by throwing an error whenever such situations are detected.
Using the rule
npm install -g remark-clinpm install remark-lint remark-lint-heading-whitespace
Then, set up your
Now you can use the following command to run the lint:
npm install -g remark-clinpm install remark-lint remark-lint-heading-whitespaceremark -u lint -u lint-heading-whitespace xxx.md