Closed6

【Neovim】null-lsを利用してtextlintを動かす

koga1020koga1020

textlint

project固有で使うことがあまりないため、globalに入れていく

$ npm install -g textlint textlint-rule-prh textlint-rule-preset-jtf-style textlint-rule-preset-ja-technical-writing textlint-rule-terminology textlint-rule-preset-ja-spacing
koga1020koga1020

HOMEに .textlintrc を設置する。ruleはお好みで。

https://github.com/textlint-ja/textlint-rule-preset-ja-technical-writing

{
  "filters": {},
  "rules": {
    "preset-ja-technical-writing": {
      "arabic-kanji-numbers": true,
      "ja-no-weak-phrase": false,
      "ja-no-mixed-period": false,
      "no-exclamation-question-mark": false,
      "no-dropping-the-ra": true,
      "no-double-negative-ja": true,
      "ja-no-redundant-expression": true,
      "no-doubled-joshi": {
        "min_interval": 1
      }
    },
    "preset-ja-spacing": {
      "ja-space-around-code": {
        "before": true,
        "after": true
      },
    },
    "preset-jtf-style": true,
    "prh": {
      "rulePaths": ["~/.prh-rules/media/WEB+DB_PRESS.yml"]
    },
    "terminology": {
      "defaultTerms": true
    }
  }
}
このスクラップは2022/07/05にクローズされました