Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tinchoz49/eslint-config-standard-ext
An extended standard eslint configuration.
https://github.com/tinchoz49/eslint-config-standard-ext
astro eslint jsx react standard
Last synced: 15 days ago
JSON representation
An extended standard eslint configuration.
- Host: GitHub
- URL: https://github.com/tinchoz49/eslint-config-standard-ext
- Owner: tinchoz49
- License: mit
- Created: 2024-05-31T16:48:20.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-09-12T02:04:43.000Z (about 2 months ago)
- Last Synced: 2024-10-17T01:15:15.483Z (20 days ago)
- Topics: astro, eslint, jsx, react, standard
- Language: JavaScript
- Homepage:
- Size: 114 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# An `ext`ended standard eslint configuration
[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard--ext-05ae89.svg)](https://github.com/tinchoz49/eslint-config-standard-ext)
Using `almost` same rules as the original `standard`.
Almost:
- `space-before-function-paren`: **NO** more space before function paren.
- `comma-dangle`: Require trailing commas.
- `quote-props`: Consistent as needed.Thanks to [antfu/eslint-config][eslint-config] extended to support:
- Using [ESLint Stylistic](https://github.com/eslint-stylistic/eslint-stylistic)
- Designed to work with TypeScript, JSX, Vue, JSON, YAML, Toml, Markdown, etc. Out-of-box.
- Auto fix for formatting (aimed to be used standalone **without** Prettier)
- Opinionated, but [very customizable](#customization)
- [ESLint Flat config](https://eslint.org/docs/latest/use/configure/configuration-files-new), compose easily!
- Optional [React][eslint-config-react], [Svelte](eslint-config-svelte), [UnoCSS](eslint-config-unocss), [Astro](eslint-config-astro), [Solid](eslint-config-solid) support
- Optional [formatters](#eslint-config-formatters) support for formatting CSS, HTML, XML, Astro, etc.
- Respects `.gitignore` by default
- Supports ESLint v9 or v8.50.0+## Install
```bash
$ npm install --save-dev eslint eslint-config-standard-ext
```## Usage
create eslint.config.(m)js in your project root:
```js
// eslint.config.js
import { standard } from 'eslint-config-standard-ext'export default standard()
```## Improved support for Astro files
```ts
// eslint.config.js
import { standard } from 'eslint-config-standard-ext'export default standard({
astro: {
config: 'all' | 'base' | 'recommended' | 'jsx-a11y-recommended' | 'jsx-a11y-strict' | undefined,
overrides: {} | undefined
} | true
})
```## Customization
It uses same options as [antfu/eslint-config](https://github.com/antfu/eslint-config?tab=readme-ov-file#customization)
Additional options:
- **javascript.organizeImports**: `boolean=true` Add support for sorting imports/exports.
[eslint-config]: https://github.com/antfu/eslint-config
[eslint-config-react]: https://github.com/antfu/eslint-config#react
[eslint-config-svelte]: https://github.com/antfu/eslint-config#svelte
[eslint-config-unocss]: https://github.com/antfu/eslint-config#unocss
[eslint-config-astro]: https://github.com/antfu/eslint-config#astro
[eslint-config-solid]: https://github.com/antfu/eslint-config#solid
[eslint-config-formatters]: https://github.com/antfu/eslint-config#formatters