1.0.0 • Published 7 years ago
eslint-off-rules v1.0.0
eslint-off-rules
Returns an ESLint rules config object of all provided ruleId
s set to "off".
Why?
Because you may like to ignore some rules.
How?
Example
.eslintrc.js
:
const off = require('eslint-off-rules')
const config = {
rules: {
'no-console': 'error',
'no-debugger': 'error'
}
}
const offRules = off(['semi', 'quotes']) // { semi: 'off', quotes: 'off' }
Object.assign(config.rules, offRules)
module.exports = config
API
fn(ruleIds)
rules
array ofruleId
s
Returns an object which has
properties named after each of the provided ruleId
s
and in which all of the values are 'off'
.
1.0.0
7 years ago