Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 | 1x | /* eslint-env commonjs */
/* eslint-disable import/unambiguous */
/* eslint-disable import/no-commonjs */
module.exports = {
rules: {
// Enforce getter and setter pairs in objects
'accessor-pairs': 'error',
// Enforce return statements in callbacks of array methods
'array-callback-return': 'error',
// Enforce the use of variables within the scope they are defined
'block-scoped-var': 'error',
// Enforce that class methods utilize this
'class-methods-use-this': 'error',
// Enforce a maximum cyclomatic complexity allowed in a program
complexity: 'error',
// Require return statements to either always or never specify values
'consistent-return': 'error',
// Enforce consistent brace style for all control statements
curly: 'error',
// Require default cases in switch statements
'default-case': 'error',
// Enforce default clauses in switch statements to be last
'default-case-last': 'error',
// Enforce default parameters to be last
'default-param-last': 'error',
// Enforce consistent newlines before and after dots
'dot-location': 'off',
// Enforce dot notation whenever possible
'dot-notation': 'error',
// Require the use of === and !==
eqeqeq: 'error',
// Require grouped accessor pairs in object literals and classes
'grouped-accessor-pairs': 'error',
// Require for-in loops to include an if statement
'guard-for-in': 'error',
// Enforce a maximum number of classes per file
'max-classes-per-file': 'error',
// Disallow the use of alert, confirm, and prompt
'no-alert': 'error',
// Disallow the use of arguments.caller or arguments.callee
'no-caller': 'error',
// Disallow lexical declarations in case clauses
'no-case-declarations': 'error',
// Disallow returning value from constructor
'no-constructor-return': 'error',
// Disallow division operators explicitly at the beginning of regular expressions
'no-div-regex': 'error',
// Disallow else blocks after return statements in if statements
'no-else-return': 'error',
// Disallow empty functions
'no-empty-function': 'error',
// Disallow empty destructuring patterns
'no-empty-pattern': 'error',
// Disallow null comparisons without type-checking operators
'no-eq-null': 'error',
// Disallow the use of eval()
'no-eval': 'error',
// Disallow extending native types
'no-extend-native': 'error',
// Disallow unnecessary calls to .bind()
'no-extra-bind': 'error',
// Disallow unnecessary labels
'no-extra-label': 'error',
// Disallow fallthrough of case statements
'no-fallthrough': 'error',
// Disallow leading or trailing decimal points in numeric literals
'no-floating-decimal': 'error',
// Disallow assignments to native objects or read-only global variables
'no-global-assign': 'error',
// Disallow shorthand type conversions
'no-implicit-coercion': 'error',
// Disallow variable and function declarations in the global scope
'no-implicit-globals': 'error',
// Disallow the use of eval()-like methods
'no-implied-eval': 'error',
// Disallow this keywords outside of classes or class-like objects
'no-invalid-this': 'error',
// Disallow the use of the __iterator__ property
'no-iterator': 'error',
// Disallow labeled statements
'no-labels': 'error',
// Disallow unnecessary nested blocks
'no-lone-blocks': 'error',
// Disallow function declarations and expressions inside loop statements
'no-loop-func': 'error',
// Disallow magic numbers
'no-magic-numbers': 'off',
// Disallow multiple spaces
'no-multi-spaces': 'error',
// Disallow multiline strings
'no-multi-str': 'error',
// Disallow new operators outside of assignments or comparisons
'no-new': 'error',
// Disallow new operators with the Function object
'no-new-func': 'error',
// Disallow new operators with the String, Number, and Boolean objects
'no-new-wrappers': 'error',
// Disallow octal literals
'no-octal': 'error',
// Disallow octal escape sequences in string literals
'no-octal-escape': 'error',
// Disallow reassigning function parameters
'no-param-reassign': 'error',
// Disallow the use of the __proto__ property
'no-proto': 'error',
// Disallow variable redeclaration
'no-redeclare': 'error',
// Disallow certain properties on certain objects
'no-restricted-properties': 'error',
// Disallow assignment operators in return statements
'no-return-assign': 'error',
// Disallow unnecessary return await
'no-return-await': 'error',
// Disallow javascript: urls
'no-script-url': 'error',
// Disallow assignments where both sides are exactly the same
'no-self-assign': 'error',
// Disallow comparisons where both sides are exactly the same
'no-self-compare': 'error',
// Disallow comma operators
'no-sequences': 'error',
// Disallow throwing literals as exceptions
'no-throw-literal': 'error',
// Disallow unmodified loop conditions
'no-unmodified-loop-condition': 'error',
// Disallow unused expressions
'no-unused-expressions': 'error',
// Disallow unused labels
'no-unused-labels': 'error',
// Disallow unnecessary calls to .call() and .apply()
'no-useless-call': 'error',
// Disallow unnecessary catch clauses
'no-useless-catch': 'error',
// Disallow unnecessary concatenation of literals or template literals
'no-useless-concat': 'error',
// Disallow unnecessary escape characters
'no-useless-escape': 'error',
// Disallow redundant return statements
'no-useless-return': 'error',
// Disallow void operators
'no-void': 'error',
// Disallow specified warning terms in comments
'no-warning-comments': 'warn',
// Disallow with statements
'no-with': 'error',
// Enforce using named capture group in regular expression
'prefer-named-capture-group': 'error',
// Require using Error objects as Promise rejection reasons
'prefer-promise-reject-errors': 'error',
// Disallow use of the `RegExp` constructor in favor of regular expression literals
'prefer-regex-literals': 'error',
// Enforce the consistent use of the radix argument when using parseInt()
radix: 'error',
// Disallow async functions which have no await expression
'require-await': 'off',
// Enforce the use of u flag on RegExp
'require-unicode-regexp': 'error',
// Require var declarations be placed at the top of their containing scope
'vars-on-top': 'error',
// Require parentheses around immediate function invocations
'wrap-iife': 'error',
// Require or disallow “Yoda” conditions
yoda: 'error',
},
}
|