textlint-rule-preset-elasticpath

1.0.1 • Public • Published

textlint-rule-preset-elasticpath

This is a textlint preset used by documentation repositories of elastic path. It consist of the textlint rules and there configurations as per the documentation practices followed by elastic path.

Installation

Since this is a textlint preset, first install textlint by following the textlint getting started guide.
This is published as an npm package that can be installed as follows

  1. Using npm npm install textlint-rule-preset-elasticpath
  2. Using yarn yarn add textlint-rule-preset-elasticpath

Usage

  • Create a .textlintrc file if none exists
  • Add the following configuration
        {
            "rules": {
                "preset-elasticpath": true
            }
        }

Please refer to configuring textlint for further details on configuring textlint

Contributing

Prerequistic

For any kind of contribution first follow these steps

  1. Install git and npm
  2. Clone this repository with command
    git clone git@code.elasticpath.com:internal-pd/docs-tools-textlint-rule-preset.git
  3. Navigate to the repository
  4. Run npm install

Add new textlint rule

  1. Add the rule as npm dependency by running npm install rule-package-name
  2. Add the rule-package-name as an element of json array in rulePackages.json
  3. By default all the rules added to rulePackages.json are enabled with default configuration. If custom configurations are required for this rule, add them in customRulesConfig.js. Note the key of custom configurations must be rule-package-name

Change configuration for an existing rule

Modify customRulesConfig.js as needed

Remove a rule

  1. Remove rule from dependencies by running npm uninstall rule-package-name --save
  2. Remove rule from the array in rulePackages.json
  3. If the rule have custom configuration in customRulesConfig.js, remove those configurations and key value pair for the rule from the exported object.

Submit Changes

  1. Check that the proposed changes passes against all the elastic path documentation projects
  2. Create a merge request and tag the maintainer for review

Package Sidebar

Install

npm i textlint-rule-preset-elasticpath

Weekly Downloads

2

Version

1.0.1

License

MIT

Unpacked Size

12.1 kB

Total Files

9

Last publish

Collaborators

  • pakkas-ep