Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jupiterone/eslint-config
https://github.com/jupiterone/eslint-config
Last synced: 7 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/jupiterone/eslint-config
- Owner: JupiterOne
- License: mit
- Created: 2020-11-25T02:30:38.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2023-12-05T17:50:12.000Z (11 months ago)
- Last Synced: 2024-09-21T14:47:51.197Z (about 2 months ago)
- Language: JavaScript
- Size: 70.3 KB
- Stars: 0
- Watchers: 13
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
# @jupiterone/eslint-config
This package provides the standard JupiterOne `eslint` configuration.
This configuration extends the following:
- `eslint:recommended`
- `prettier`It also provides linting support for TypeScript files via
`@typescript-eslint/parser`.## Usage
**Install package:**
```sh
yarn add @jupiterone/eslint-config --dev
```**For Node.js apps targeting Node.js v18:**
```js
// .eslintrc
{
"root": true,
"extends": [
"@jupiterone/eslint-config/node18"
],
"parserOptions": {
"project": "./tsconfig.json",
"tsconfigRootDir": "."
}
}
```**NOTE:** You can also target other versions of Node.js by extending one of the
following configurations:- `@jupiterone/eslint-config/node14` (ECMA version 2020)
- `@jupiterone/eslint-config/node16` (ECMA version 2021)
- `@jupiterone/eslint-config/node18` (ECMA version 2022)**An experimental React configuration is also provided:**
```js
// .eslintrc
{
"root": true,
"extends": [
"@jupiterone/eslint-config/react"
],
"parserOptions": {
"project": "./tsconfig.json",
"tsconfigRootDir": "."
}
}
```**This package automatically applies `jest` liniting rules to the following
files:**- `jest.*.js`
- `test/**/*.{ts,tsx,js,jsx}`
- `*.test.{ts,tsx,js,jsx}`
- `__mocks__/**/*.{ts,tsx,js,jsx}`