textlint

The pluggable natural language linter for text and markdown.

MIT License

Downloads
7.4M
Stars
2.8K
Committers
83

Bot releases are visible (Hide)

textlint -

Published by azu over 7 years ago

8.2.1 (2017-05-21)

Bug Fixes

  • textlint: fix config.configFile is undefined at sometimes (#297) (cd64560), closes #297
textlint -

Published by azu over 7 years ago

8.2.0 (2017-05-21)

Features

  • textlint-kernel: add configBaseDir option (#295) (85dad8a)
textlint -

Published by azu over 7 years ago

Features

This is main logic of textlint.
Also it is Universal JavaScript. It means that no-depended on platform like Node.js.

textlint -

Published by azu over 7 years ago

8.0.1 (2017-05-11)

Bug Fixes

  • textlint: remove shelljs dependencies (#287) (0e88942)
textlint -

Published by azu over 7 years ago

BREAKING CHANGES

  • textlint: markdown-to-ast@4 includes some breaking change
  • It enhance some linting result.
    • use remark@7 #278

Bug Fixes

  • textlint: fix thrown error when --fix empty result. (#274) (7013cee), closes #274
  • textilnt: fix JSDoc (8a417e0)

Features

  • packages: import textlint-plugin-text (1b7a571)
  • textlint: update built-in textlint-plugin-markdown@^2 (#282) (448fef9)
textlint -

Published by azu over 7 years ago

Features

  • cli: Support quiet mode #268

Now, work textlint --quite.

Thanks to @fand

textlint -

Published by azu over 7 years ago

Features

  • #261 #264 Support glob pattern

$ textlint "*pattern" (need to wrap ")

textlint "./docs/"
# Results
[ 'docs/configuring.md',
  'docs/faq/failed-to-load-textlints-module.md',
  'docs/faq/line-column-or-index.md',
  'docs/filter-rule.md',
  'docs/formatter.md',
  'docs/getting-started.md',
  'docs/plugin.md',
  'docs/README.md',
  'docs/rule-advanced.md',
  'docs/rule-fixable.md',
  'docs/rule-preset.md',
  'docs/rule.md',
  'docs/txtnode.md',
  'docs/use-as-modules.md' ]
textlint "./docs/**"
# Results
[ 'docs/configuring.md',
  'docs/faq/failed-to-load-textlints-module.md',
  'docs/faq/line-column-or-index.md',
  'docs/filter-rule.md',
  'docs/formatter.md',
  'docs/getting-started.md',
  'docs/plugin.md',
  'docs/README.md',
  'docs/rule-advanced.md',
  'docs/rule-fixable.md',
  'docs/rule-preset.md',
  'docs/rule.md',
  'docs/txtnode.md',
  'docs/use-as-modules.md' ]
textlint "./docs/faq/*.md"
# Results
[ 'docs/faq/failed-to-load-textlints-module.md',
  'docs/faq/line-column-or-index.md' ]
textlint -

Published by azu over 7 years ago

Fixes:

  • fix(config): use rc-config-loader insteadof rc-loader #262 #39

This change also fix following issue.

webpack2 + textlint throw error like this.

ERROR in ./~/rc/index.js
Module parse failed: /Users/azu/.ghq/github.com/textlint/textlint.github.io/node_modules/rc/index.js Unexpected character '#' (1:0)
You may need an appropriate loader to handle this file type.
| #! /usr/bin/env node
| var cc   = require('./lib/utils')
| var join = require('path').join
 @ ./~/rc-loader/dist/index.js 10:10-23
 @ ./~/textlint/lib/config/config-loader.js
 @ ./~/textlint/lib/config/config.js
 @ ./~/textlint/lib/cli.js
 @ ./~/textlint/lib/index.js
 @ ./src/components/TextlintDemo/TextlintEditor.js
 @ ./src/components/TextlintDemo.js
 @ ./src/components/App.js
 @ ./src/index.js
textlint - https://github.com/textlint/textlint/releases/tag/7.2.1

Published by azu almost 8 years ago

Bug Fixes

  • config: --cache-location doesn't support directory yet. (325df3f)
textlint -

Published by azu almost 8 years ago

Features

  • cli: --cache && --cache-location support (#251) (04533c7)

--cache:

Store the info about processed files in order to only operate on the changed ones.

textlint --cache docs/

--cache-location:

Path to the cache location. Default: .textlintcache

textlint - https://github.com/textlint/textlint/releases/tag/7.1.4

Published by azu almost 8 years ago

textlint - https://github.com/textlint/textlint/releases/tag/7.1.3

Published by azu almost 8 years ago

Bug Fixes

  • bin: not use Arrow Function (f69ae96)

Performance Improvements

textlint -

Published by azu about 8 years ago

Bug Fixes

  • use is-file insteadof exists-sync (d15ff60)
textlint - https://github.com/textlint/textlint/releases/tag/7.1.1

Published by azu about 8 years ago

Bug Fixes

  • d.ts: export as a class (f757b4b)
  • fixer: fix to work commands that accept Node (ed1d52b), closes #229
  • jsdoc: fix invalid JSDoc (aca3148)
textlint -

Published by azu about 8 years ago

Features

  • cli: --init fill with installed rules (3948147), closes #129
textlint -

Published by azu over 8 years ago

Bug Fixes

textlint - https://github.com/textlint/textlint/releases/tag/7.0.1

Published by azu over 8 years ago

Bug Fixes

  • core: remove --experimental flag of shouldIgnore() (b1e2a17)
textlint -

Published by azu over 8 years ago

Features

Filter rule 🆕

  • "filter rule" support #216 #207

Filter rule provide filtering error that is reported by linting rule.

For example, textlint-filter-rule-comments provide filtering function by using comments.

<!-- textlint-disable -->

Disables all rules between comments

<!-- textlint-enable -->`

Allow to short textlint-filter-rule-comments to comments.

Add filter rule name to filters field.

{
  "filters": {
    "comments": true
  }
}

One more example, very-nice-rule is useful, but you want to ignore some reported error in your text.
very-nice-rule also check the BlockQuote text, but you want to ignore the BlockQuote text.
textlint-filter-rule-node-types rule resolve the issue.

{
  "filters": {
    "node-types": {
      "nodeTypes": ["BlockQuote"]
    }
  },
  "rules": {
    "very-nice-rule": true
  }
}

Sharable Config 🆕

  • config: --config @textlint/textlint-config support (a059df7)

See Sharable Configuration for details.

Example : azu/textlint-config-readme: Sharable config for textlint

You can use the config via two step.

npm i -D @azu/textlint-config-readme textlint
$(npm bin)/textlint --config @azu/textlint-config-readme README.md

Breaking Change ⚠️

textlint 7.0 has some breaking change.
It will not affect textlint user, but affect to textlint rule developer.

Ignore duplicated messages by default #209

Duplicated messages is ignored by default.

Duplicated messages is that have same range and same message.
(Not depended on ruleId. ruleId is flexible property)

Sort messages by line and column #218

textlint 7.0 sort message by line and column.
The rule that depended on the order of messages may fail test.

Drop Node.js 0.12 support #215

textlint 7.0 not support Node.js 0.12. (But still it work)
Requirement: Node.js 4.0.0 >=

textlint - 7.0.0 beta release

Published by azu over 8 years ago

This is beta release

Please try it :)

npm install textlint@beta

Features

Filter rule

  • "filter rule" support #216 #207

Filter rule provide filtering error that is reported by linting rule.

For example, textlint-filter-rule-comments provide filtering function by using comments.

<!-- textlint-disable -->

Disables all rules between comments

<!-- textlint-enable -->`

Allow to short textlint-filter-rule-comments to comments.

Add filter rule name to filters field.

{
  "filters": {
    "comments": true
  }
}

One more example, very-nice-rule is useful, but you want to ignore some reported error in your text.
very-nice-rule also check the BlockQuote text, but you want to ignore the BlockQuote text.
textlint-filter-rule-node-types rule resolve the issue.

{
  "filters": {
    "node-types": {
      "nodeTypes": ["BlockQuote"]
    }
  },
  "rules": {
    "very-nice-rule": true
  }
}

Sharable Config

  • config: --config @textlint/textlint-config support (a059df7)

See Sharable Configuration for details.

Example : azu/textlint-config-readme: Sharable config for textlint

You can use the config via two step.

npm i -D @azu/textlint-config-readme textlint
$(npm bin)/textlint --config @azu/textlint-config-readme README.md

Breaking Change

textlint 7.0 has some breaking change.
It will not affect textlint user, but affect to textlint rule developer.

Ignore duplicated messages by default #209

Duplicated messages is ignored by default.

Duplicated messages is that have same range and same message.
(Not depended on ruleId. ruleId is flexible property)

Sort messages by line and column #218

textlint 7.0 sort message by line and column.
The rule that depended on the order of messages may fail test.

Drop Node.js 0.12 support #215

textlint 7.0 not support Node.js 0.12. (But still it work)
Requirement: Node.js 4.0.0 >=

textlint -

Published by azu over 8 years ago

Documents

ast-explorer for textlint

AST explorer for textlint is useful for understanding AST.

  • Add filter rules document #221

Features

  • debug: add debug log to task (c05a7b3)

Try to run DEBUG=textlint* textlint README