Gathering detailed insights and metrics for eslint-plugin-gb
Gathering detailed insights and metrics for eslint-plugin-gb
Gathering detailed insights and metrics for eslint-plugin-gb
Gathering detailed insights and metrics for eslint-plugin-gb
npm install eslint-plugin-gb
Typescript
Module System
Node Version
NPM Version
55.3
Supply Chain
86.8
Quality
80.9
Maintenance
100
Vulnerability
98.9
License
JavaScript (100%)
Total Downloads
7,835
Last Day
10
Last Week
36
Last Month
216
Last Year
3,390
74 Commits
3 Watching
1 Branches
1 Contributors
Latest Version
9.1.0
Package Id
eslint-plugin-gb@9.1.0
Unpacked Size
8.22 kB
Size
2.61 kB
File Count
9
NPM Version
10.8.2
Node Version
20.17.0
Publised On
04 Oct 2024
Cumulative downloads
Total Downloads
Last day
100%
10
Compared to previous day
Last week
-55.6%
36
Compared to previous week
Last month
-19.7%
216
Compared to previous month
Last year
37.1%
3,390
Compared to previous year
1
3
My favorite eslint configurations for ESLint >=9. A version for earlier ESLint releases in available on eslint-plugin-gb@2.
1npm add --save-dev typescript 2npm add --save-dev eslint 3npm add --save-dev @typescript-eslint/parser 4npm add --save-dev @typescript-eslint/eslint-plugin 5npm add --save-dev eslint-plugin-gb 6
see Configuration Files - ESLint - Pluggable JavaScript Linter for detailed information. For the basics add the eslint.config.js
to the root of your project.
1// eslint.config.cjs 2const js = require('@eslint/js'); 3const gb = require('eslint-plugin-gb'); 4 5module.exports = [ 6 ...js.configs.recommended, 7 ...gb.configs['flat/recommended'], 8 { 9 files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'], 10 // Override or add rules here 11 rules: {}, 12 }, 13];
1// eslint.config.mjs 2import js from "@eslint/js"; 3import ts from "typescript-eslint"; 4import gb from "eslint-plugin-gb"; 5import globals from "globals"; 6 7/** @type {import('eslint').Linter.Config[]} */ 8export default [ 9 js.configs.recommended, 10 ...ts.configs.recommended, 11 ...gb.configs["flat/recommended"], 12];
recommended
configRule | Setting |
---|---|
@typescript-eslint/consistent-type-imports | warn |
@typescript-eslint/explicit-member-accessibility | warn |
@typescript-eslint/explicit-module-boundary-types | warn |
@typescript-eslint/member-ordering | warn (with alphabetical ordering and strict rules.) |
@typescript-eslint/no-unused-vars | off |
recommended-type-checked
configall of the recommended
rules and also the following.
Rule | Setting |
---|---|
@typescript-eslint/no-floating-promises | warn |
@typescript-eslint/unbound-method | error |
This is a bare-bones library. There are no npm scripts or monorepo plugins. npx prettier . -w
works ok.
eslint-plugin-gb version | eslint version |
---|---|
^9.0.0 | >=9.0.0 |
^2.0.0 | <9.0.0 |
No vulnerabilities found.
No security vulnerabilities found.