https://github.com/k-yle/eslint-config-kyle
💚
https://github.com/k-yle/eslint-config-kyle
Last synced: 8 months ago
JSON representation
💚
- Host: GitHub
- URL: https://github.com/k-yle/eslint-config-kyle
- Owner: k-yle
- License: mit
- Created: 2020-04-19T01:52:48.000Z (about 6 years ago)
- Default Branch: main
- Last Pushed: 2025-02-07T21:33:34.000Z (over 1 year ago)
- Last Synced: 2025-02-07T22:30:12.287Z (over 1 year ago)
- Language: JavaScript
- Homepage: https://npm.im/eslint-config-kyle
- Size: 1.7 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# eslint-config-kyle
[](https://github.com/k-yle/eslint-config-kyle/actions)
[](https://badge.fury.io/js/eslint-config-kyle)
💚 The eslint config I use for all my side projects.
A stricter version of the airbnb config with TS support.
## Usage (Flat Config)
Requires eslint ≥9 and node ≥18.18
```sh
npm i -D eslint-config-kyle eslint
```
Add the following to `package.json`:
```json
{
"scripts": { "lint": "eslint ." },
"prettier": "eslint-config-kyle/prettier"
}
```
And create a file called `eslint.config.js`:
```js
export { default } from 'eslint-config-kyle';
```
And add this to your `tsconfig.json` file:
```jsonc
{
"extends": "eslint-config-kyle/tsconfig",
}
```
## Usage (Legacy)
```sh
npm i -D eslint-config-kyle@22 eslint@8
```
Add the following to `package.json`:
```json
{
"eslintConfig": { "extends": "kyle" },
"prettier": "eslint-config-kyle/prettier"
}
```
## VS Code configuration
```jsonc
{
// By default, VS Code will not show eslint errors
// for css files, so we need to add this snippet:
"eslint.validate": [
"css",
"json",
"javascript",
"javascriptreact",
"typescript",
"typescriptreact",
],
// for the best DX, enable format-on-save and
// lint-on-save.
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit",
},
// optional, if the local vs global versions conflict.
// the exact syntax would depend on your package manager.
"prettier.prettierPath": "./node_modules/prettier",
}
```