eslint-plugin-rql
Eslint plugin which provides lint rules for RQL queries
Installation
You'll first need to install ESLint:
$ npm i eslint --save-dev
Next, install @rql/eslint-plugin
:
$ npm install @rql/eslint-plugin --save-dev
Usage
Add rql
to the plugins section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": [
"@rql"
]
}
Then configure the rules you want to use under the rules section.
{
"rules": {
"@rql/rule-name": 2
}
}
Supported Rules
Name | Description |
---|---|
@rql/no-undeclared-var |
Require selected variables to appear in the restriction part of search queries. |