hexojs / hexo-renderer-markdown-it

Markdown-it is a Markdown parser, done right. A faster and CommonMark compliant alternative for Hexo.
MIT License
343 stars 60 forks source link

fix: set default config #90

Closed curbengh closed 4 years ago

curbengh commented 4 years ago

mainly to enable anchor links to be compatible with toc() helper. Fixes https://github.com/theme-next/hexo-theme-next/issues/1168

All defaults are set in consistent with hexo-renderer-marked.

cc @anthonyhan

curbengh commented 4 years ago

Ready for review.

curbengh commented 4 years ago

breaks should be true by default, to be consistent with hexo-renderer-marked's default.

SukkaW commented 4 years ago

This change might break current users'. We should mention it in release notes.

curbengh commented 4 years ago

This change might break current users'. We should mention it in release notes.

I intend to do a major bump (to v4) after this. I also mention the defaults in the readme.

tomap commented 4 years ago

Maybe add in the doc the config to use to keep the current defaults <v4

curbengh commented 4 years ago

Maybe add in the doc the config to use to keep the current defaults <v4

I can mention in the release note. there were no defaults prior to v4, to keep the defaults, can specify key with no value,

markdown:
  render:
  plugins:
  anchors:

I don't think it's necessary to put it in readme/wiki; by releasing a new version, we essentially drop support for prior versions.