Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/autosseyai/eslint-config
A base for projects that use ESLint.
https://github.com/autosseyai/eslint-config
eslint eslint-config react typescript typescript-react
Last synced: about 2 months ago
JSON representation
A base for projects that use ESLint.
- Host: GitHub
- URL: https://github.com/autosseyai/eslint-config
- Owner: AutosseyAI
- Created: 2023-09-25T12:29:25.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-03T12:30:59.000Z (over 1 year ago)
- Last Synced: 2024-11-15T04:25:17.209Z (about 2 months ago)
- Topics: eslint, eslint-config, react, typescript, typescript-react
- Language: TypeScript
- Homepage: https://www.npmjs.com/package/@autossey/eslint-config
- Size: 17.6 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
A base for projects that use ESLint.
_If I should maintain this repo, please ⭐️_
_DM me on [Twitter](https://twitter.com/bconnorwhite) if you have questions or suggestions._
---
This package provides a base ESLint config for TypeScript, and a second for TypeScript with React.
## Installation
```sh
npm install --save-dev @autossey/eslint-config
``````sh
yarn add --dev @autossey/eslint-config
```
```sh
pnpm add --save-dev @autossey/eslint-config
```
```sh
bun add --dev @autossey/eslint-config
```## Usage
In your `package.json` file:
**TypeScript**
This is a generic config for projects that use TypeScript.
```json
{
"eslintConfig": {
"extends": "@autossey/eslint-config"
}
}
```**Node**
The `node` config extends the `typescript` config and adds rules for Node.js.
```json
{
"eslintConfig": {
"extends": "@autossey/eslint-config/node"
}
}
```**React**
The `react` config extends the `typescript` config and adds rules for React.
```json
{
"eslintConfig": {
"extends": "@autossey/eslint-config/react"
}
}
```### Running ESLint
Now to run ESLint, run `yarn eslint source` or `npm run eslint source`.
## Updates
As this package updates, bug fixes are considered patch updates as usual.
Rule changes are considered minor updates. Rule changes can cause linting errors in your code, If you want to avoid rule changes, you can set your package to use a specific minor version of this package with the `~` operator:
```json
{
"devDependencies": {
"@autossey/eslint-config": "~0.2.0"
}
}
```
Dependencies
- [@types/eslint](https://www.npmjs.com/package/@types/eslint): TypeScript definitions for eslint
- [@typescript-eslint/eslint-plugin](https://www.npmjs.com/package/@typescript-eslint/eslint-plugin): TypeScript plugin for ESLint
- [@typescript-eslint/parser](https://www.npmjs.com/package/@typescript-eslint/parser): An ESLint custom parser which leverages TypeScript ESTree
- [eslint-plugin-i](https://www.npmjs.com/package/eslint-plugin-i): A fork of `eslint-plugin-import` using `get-tsconfig` to replace `tsconfig-paths` and heavy `typescript` under the hood.
- [eslint-plugin-json](https://www.npmjs.com/package/eslint-plugin-json): eslint plugin for JSON files
- [eslint-plugin-n](https://www.npmjs.com/package/eslint-plugin-n): Additional ESLint's rules for Node.js
- [eslint-plugin-react](https://www.npmjs.com/package/eslint-plugin-react): React specific linting rules for ESLint
- [eslint-plugin-react-hooks](https://www.npmjs.com/package/eslint-plugin-react-hooks): ESLint rules for React Hooks
Peer Dependencies
- [eslint](https://www.npmjs.com/package/eslint): An AST-based pattern checker for JavaScript.
Dev Dependencies
- [@autossey/tsconfig](https://www.npmjs.com/package/@autossey/tsconfig): A collection of base TSConfigs for various types of projects.
- [eslint](https://www.npmjs.com/package/eslint): An AST-based pattern checker for JavaScript.
License
[MIT](https://opensource.org/licenses/MIT) - _MIT License_