Pangu whitespace for Chinese comments.
You'll first need to install ESLint:
$ npm i eslint --save-dev
Next, install eslint-plugin-pangu-comment
:
$ npm install eslint-plugin-pangu-comment --save-dev
Note: If you installed ESLint globally (using the -g
flag) then you must also install eslint-plugin-pangu-comment
globally.
Add pangu
to the plugins section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": [
"pangu-comment"
]
}
Then configure the rules you want to use under the rules section.
{
"rules": {
"pangu/rule-spacing": 2
}
}
- Spacing