@falcon0387/textlint-rule-sentence-length
v0.0.1
Published
textlint rule that checks sentence length in code points and excludes LaTeX math
Downloads
158
Maintainers
Readme
@falcon0387/textlint-rule-sentence-length
A textlint rule that checks sentence length in code points, excluding math expressions.
Install
bun add -D @falcon0387/textlint-rule-sentence-lengthUsage
rules:
"@falcon0387/sentence-length": trueOptions
rules:
"@falcon0387/sentence-length":
max: 360| Option | Type | Default | Description |
| --- | --- | --- | --- |
| max | number | 360 | Positive integer. Maximum sentence length in code points |
Invalid max values are treated as configuration errors.
How it works
- Code spans are masked before sentence splitting, so punctuation inside inline code does not affect sentence boundaries.
- Math expressions (
$...$,$$...$$,\(...\),\[...\],\begin{...}...\end{...}) are excluded from the sentence length via@falcon0387/textlint-rule-math-helper.
Release
Automated via release-please.
Merge the auto-generated Release PR to bump version, update CHANGELOG.md, and create a tag.
