https://github.com/hex-digital/config-eslint
https://github.com/hex-digital/config-eslint
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/hex-digital/config-eslint
- Owner: hex-digital
- License: mit
- Created: 2022-08-30T08:18:02.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2023-07-16T15:52:42.000Z (almost 3 years ago)
- Last Synced: 2026-02-13T03:36:10.930Z (5 months ago)
- Language: JavaScript
- Size: 204 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# @hexdigital/eslint-config
[](https://npmjs.com/package/@hexdigital/eslint-config)
- Single quotes, no semi
- Auto fix for formatting (aimed to be used standalone without Prettier)
- TypeScript, Vue out-of-the-box
- Lint also for json, yaml, markdown
- Sorted imports, dangling commas for cleaner commit diff
- Reasonable defaults, best practices, only one-line of config
## Usage
### Install
```bash
pnpm add -D eslint @hexdigital/eslint-config
# or
yarn add -D eslint @hexdigital/eslint-config
```
### Config `.eslintrc`
```json
{
"extends": "@hexdigital"
}
```
> You don't need `.eslintignore` normally as it has been provided by the preset.
### Add script for package.json
For example:
```json
{
"scripts": {
"lint": "eslint .",
"lint:fix": "eslint . --fix"
}
}
```
### Config VS Code auto fix
Create `.vscode/settings.json`
```json
{
"prettier.enable": false,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
}
}
```
## Releasing
```
pnpm run release
```
## Check Also
- [hex-digital/eslint-config](https://github.com/hex-digital/eslint-config) - Our ESLint config
- [hex-digital/starter-nuxt3-base](https://github.com/hex-digital/starter-nuxt3-base) - Our starter template for Vue & Nuxt3
## License
[MIT](./LICENSE) License © 2022-PRESENT [Hex Digital](https://github.com/hex-digital)
## Attribution
Big thank you to Antfu for his eslint config that this pulls heavily from.