Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
eslint-config-rickschubert
Advanced tools
ESLint Configuration "Rick Schubert" ===================================
Preferring ES6, readability and low ambiguities. Extends the recommended ruleset with some useful additions.
npm install eslint-config-rickschubert --save-dev
{
"extends": ["rickschubert"]
}
npm i @typescript-eslint/eslint-plugin @typescript-eslint/parser --save-dev
{
"extends": ["rickschubert"],
"plugins": ["@typescript-eslint"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"modules": true
}
}
}
no-unused-vars
despite them being actually used as type annotations.Environments: node
, es6
, browser
Unless noted, all rules are errors.
Rule | Description |
---|---|
arrow-parens | Always wrap function arguments in brackets. |
brace-style | Curly brackets start after the keyword, not underneath. |
comma-dangle | Dangling commas in multiline objects, functions, arrays. |
complexity | Maximum cyclomatic complexity of 3 to enforce highly maintaineable code (warning). |
curly | Curly brackets after if statements to avoid ambiguity when line breaks occur. |
eol-last | Empty line at the end of the file. |
func-call-spacing | Brackets () to invoke a function have to stand right next to the function name. |
global-require | require() statements should be at the top of the file (warning). |
linebreak-style | UNIX linebreaks. |
no-await-in-loop | Disallow await in loops (should use Promise.all() instead). |
no-default-export | Only allow named exports for increased consistency and clarity when importing modules. |
no-floating-decimal | Numbers have to be clear, i.e. 0.4 instead of .4 . |
no-implicit-coercion | Converting types from one to another have to be explicit. |
no-lone-blocks | No curly brackets unless necessary. |
no-lonely-if | Use else if instead of a lonely if wrapped inside an else . |
no-loop-func | Functions cannot be declared inside loops, they should be declared outside. |
no-template-curly-in-string | Avoid confusion whether a string is templated or not. |
no-throw-literal | Throw errors explicitly, not just strings or values. |
no-var | Use ES6 block-scopedconst and let , never var . |
one-var | Don't declare multiple variables in one line. |
prefer-const | let should only be used where reassignment is necessary. |
prefer-promise-reject-errors | Promises should be reject ed with a clear error, not a simple value. |
prefer-spread | Use ES6 spread operator instead of difficult to understand ES5 .apply() . |
prefer-template | Use template strings instead of string concatenation (warning). |
quotes | Use unescaped double quotes. |
require-await | async functions should perform an await , otherwise async keyword is unnecessary. |
semi | Don't use semicolons. |
yoda | Don't use unintuitive conditions. |
FAQs
ESLint Configuration "Rick Schubert" ===================================
The npm package eslint-config-rickschubert receives a total of 59 weekly downloads. As such, eslint-config-rickschubert popularity was classified as not popular.
We found that eslint-config-rickschubert demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.