1.0.1 • Published 4 years ago
eslint-plugin-fixclosure v1.0.1
eslint-plugin-fixclosure
this is a eslint plugin for fixclosure.
Installation
You'll first need to install ESLint and fixclosure:
$ npm i eslint fixclosure --save-devNext, install eslint-plugin-fixclosure:
$ npm install eslint-plugin-fixclosure --save-devUsage
Add fixclosure to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:
{
"plugins": [
"fixclosure"
]
}Then configure the rules you want to use under the rules section.
{
"rules": {
"fixclosure/fixclosure": "error"
}
}Supported Rules
fixclosure/fixclosure
A rule to test whether the code is compatible with fixclosure or not.
This rule supports --fix option, so you no longer write goog.require(...) manually :rocket:
You can pass the following options to fixclosure.
depsJsdeps.jsfiles, which is a comma separated list.
config- a path for
.fixclosurerc.
- a path for
provideRoots- root namespaces you use.
useForwardDeclare- Use
goog.forwardDeclare()instead ofgoog.requireType()
- Use
You can see the details on the documentation of fixclosure.