Giter VIP home page Giter VIP logo

textlint-rule-preset-smarthr's Introduction

textlint-rule-preset-smarthr

SmartHRらしい文書を書くための、textlintルールプリセットを提供します。

インストール

Install with npm:

npm install textlint-rule-preset-smarthr

使い方

Via .textlintrc(Recommended)

Via CLI

textlint --rule preset-smarthr README.md

Build

ソースコードをビルドして、libフォルダに公開します。 TypeScriptのソースコードはsrc/フォルダに書くことができます。

npm run build

Tests

testフォルダ内のテストコードを実行します。 testの詳細はtextlint-testerを参照してください。

npm test

基本設定

すべてのルールを有効化して使う場合は、次のように設定してください。

{
  "rules": {
    "preset-smarthr": true
  }
}

デフォルト設定

デフォルトでは、次のような設定になっています。個別にルールを有効・無効化することも可能です。

{
  "rules": {
    "preset-smarthr": {
      "prh-rules": true,
      "ja-no-mixed-period": true,
      "no-hankaku-kana": true,
      "@textlint-rule/no-unmatched-pair": true,
      "sentence-length": {
        "max": 120
      },
      "no-doubled-conjunctive-particle-ga": true,
      "no-double-negative-ja": true,
      "ja-no-abusage": true,
      "ja-no-redundant-expression": true,
      "no-mixed-zenkaku-and-hankaku-alphabet": true,
      "ja-keishikimeishi": {
        "detection_hou_kata" : false,
        "detection_ue" : false
      },
      "ja-hiragana-fukushi": true,
      "ja-hiragana-hojodoushi": true,
      "ja-hiragana-daimeishi": true,
      "ja-no-space-around-parentheses": true,
      "ja-no-space-between-full-width": true,
      "ja-space-between-half-and-full-width": {
        "space": "never"
      },
      "ja-space-after-exclamation": true,
      "ja-space-after-question": true,
      "ja-space-around-code": false
    }
  }
}

設定ルール一覧

補足1: textlint-rule-preset-ja-spacingのルールプリセットを分解して設定しています。

辞書設定

表記ゆれ修正用の辞書の設定にはtextlint-rule-prhを使っています。 対応用語はdict/フォルダに入っている.ymlを確認してください。

License

MIT

textlint-rule-preset-smarthr's People

Contributors

renovate[bot] avatar kgsi avatar github-actions[bot] avatar otapo avatar ibulog avatar diescake avatar kuny25 avatar alpaca-tc avatar f440 avatar masup9 avatar yamish123 avatar chick-p avatar masinc avatar kinoppyd avatar hoshinotsuyoshi avatar thaddeusjiang avatar mkmn avatar aguringo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.