2.4.2 • Published 10 days ago

textlint-rule-ja-space-around-link v2.4.2

Weekly downloads
70
License
MIT
Repository
github
Last release
10 days ago

textlint-rule-ja-space-around-link textlint rule

リンクの周りをスペースで囲むかどうかを決めるtextlintルール

リンクとはTxtASTLink nodeのことです。

このルールでは、リンクの前後が日本語である場合に半角スペースを入れるかを決定します。 オプションでスペースの有無を決定できます。

[README](README.md) と日本語の間はスペースを空ける
[README](README.md)と日本語の間はスペースを空けない

Install

Install with npm:

npm install textlint-rule-ja-space-around-link

Usage

Via .textlintrc(Recommended)

{
    "rules": {
        "ja-space-around-link": true
    }
}

Via CLI

textlint --rule ja-space-around-link README.md

Options

  • before: boolean
    • デフォルト: false
    • trueなら、Linkの前に半角スペースを入れる
  • after: boolean
    • デフォルト: false
    • trueなら、Linkの後に半角スペースを入れる

デフォルト値は次のようになります。

{
    "rules": {
        "ja-space-around-link": {
            "before": false,
            "after": false
        }
    }
}

Fixable

textlint rule

textlint --fixの自動修正に対応しています。

Changelog

See Releases page.

Running tests

Install devDependencies and Run npm test:

npm i -d && npm test

Contributing

Pull requests and stars are always welcome.

For bugs and feature requests, please create an issue.

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -am 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

Author

License

MIT © 0x6b