Skip to content

v2.0.0

Compare
Choose a tag to compare
@github-actions github-actions released this 04 Oct 02:58
· 383 commits to main since this release

New features

  • core: Add rules config, now you can configure rule in .autocorrectrc.

  • core: Improve Markdown parser to identify the indented style code block for fix .

  • core: Allows to use autocorrect-disable <rule> to disable some rules.

  • 重构 Format 拆分 Rule,每个 Rule 定义名称,Rule 支持通过配置来开关。

  • Rule 支持配置 severity,检查的时候根据 severity 决定 Lint 展示。

  • 允许采用 autocorrect-disable <rule> 注释来禁用某些规则。

Rules

rules:
  # Auto add spacing between CJK (Chinese, Japanese, Korean) and English words.
  # 0 - off, 1 - error, 2 - warning
  space-word: 1
  # Add space between some punctuations.
  space-punctuation: 1
  # Convert to fullwidth.
  fullwidth: 1
  # Convert to halfwidth.
  halfwidth: 1
  # To remove space near the fullwidth.
  no-space-fullwidth: 1
  # Spellcheck
  spellcheck: 2

Deprecated

  • Deprecated format_html method, use format_for instead.
  • Deprecated spellcheck.mode config, use rules.spellcheck instead.

Fix

  • core: Fix line number position when in inline scripts. #85
  • core: Fix markdown parse meta info issue #84