https://github.com/rixo/rixo-eslint
Rixo's all things eslint
https://github.com/rixo/rixo-eslint
Last synced: 5 months ago
JSON representation
Rixo's all things eslint
- Host: GitHub
- URL: https://github.com/rixo/rixo-eslint
- Owner: rixo
- Created: 2019-05-17T09:46:31.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2023-08-05T04:34:22.000Z (almost 3 years ago)
- Last Synced: 2025-06-16T17:44:07.499Z (about 1 year ago)
- Language: JavaScript
- Size: 671 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 14
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Monorepo for all my eslint & prettier stuff, in a easily sharable form.
# Installation
```bash
npm install --dev @rixo/eslint-config
```
You can have your `.eslintrc` and `.prettierrc` files can be created automatically for you by running the provided script:
```bash
npm run rixo-eslint-init
```
If these files already exists in your project, then they won't be touched.
Not too sure about Windows support currently, but if the script doesn't work for you, you can refer to the variants section to create the files yourself.
# Usage
Just use eslint, & prettier...
```bash
npx eslint src
npx prettier 'src/**/*'
npx prettier --write 'src/**/*'
```
You can customize your rules in `.eslintrc` too.
# Customization
## Disable plugin
All variants include [eslint-plugin-disable][eslint-plugin-disable] so you can always disable a plugin that was added automatically, if the combination does not work well for you.
`eslint-plugin-disable` supports disabling in `.eslintrc` or on a per-file basis, with a comment:
```js
/* eslint-plugin-disable import, prettier */
```
# Variants
Note: the example bellow use the shortcut form of extends, but feel free to use an array if you want to extend from other config.
Example:
```yml
# .eslintrc
extends:
- '@rixo'
- 'plugin:whatever'
```
## Default
```yml
# .eslintrc
extends: '@rixo'
```
## Svelte
With added support for Svelte syntax (in both eslint & prettier).
```yml
# .eslintrc
extends: '@rixo/svelte'
```
## Atom
Specific rules for development of Atom packages.
```yml
# .eslintrc
extends: '@rixo/atom'
```
[eslint-plugin-disable]: https://github.com/mradionov/eslint-plugin-disable