Skip to content

2.0.1

Choose a tag to compare

@azu azu released this 19 Jan 15:15
· 62 commits to master since this release

Fixes

  • Fix position to report in a certain cases #5

When the second or later sentence in the paragraph contains many tens, the rule reports wrong position in some cases.

$ cat problematic_cases.md
複数のセンテンスがある場合。これでも、columnが、ちゃんと計算、されているはずです。

複数のセンテンスがあって、改行されている場合でも
大丈夫です。これでも、lineとcolumnが、ちゃんと計算、されているはずです。

Before

Reports wrong position.

$ textlint --rule max-ten problematic_cases.md

/private/tmp/problematic_cases.md
  1:20  error  一つの文で"、"を3つ以上使用しています  max-ten
  3:25  error  一つの文で"、"を3つ以上使用しています  max-ten

✖ 2 problems (2 errors, 0 warnings)

After

Reports correct position.

$ textlint --rule max-ten problematic_cases.md

/private/tmp/problematic_cases.md
  1:34  error  一つの文で"、"を3つ以上使用しています  max-ten
  4:31  error  一つの文で"、"を3つ以上使用しています  max-ten

✖ 2 problems (2 errors, 0 warnings)

Thanks @orangain