@kouts/eslint-config 3.1.5 → 3.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -2,9 +2,9 @@
2
2
 
3
3
  > Custom ESLint and Prettier config with Vue.js support and sensible defaults
4
4
 
5
- > [!NOTE]
6
- > Starting from v1, this ESLint config uses the [ESLint Flat config](https://eslint.org/docs/latest/use/configure/configuration-files-new) and is only compatible with ESLint v9 or v8.50.0+.
7
- > If you're looking for the previous version, checkout the [README]('./README_V0.md') here.
5
+ > [!NOTE]
6
+ > This config uses the [ESLint Flat config](https://eslint.org/docs/latest/use/configure/configuration-files-new), requires Node.js `^22.13.0 || >=24`, and supports ESLint 10.
7
+ > If you're looking for the previous version, see [README_V0.md](./README_V0.md).
8
8
 
9
9
  ## Installation
10
10
 
@@ -22,9 +22,7 @@ Add an `eslint.config.js` (or `eslint.config.cjs` if your project is CommonJS) t
22
22
  import { config } from '@kouts/eslint-config'
23
23
 
24
24
  export default [
25
- ...config({
26
- env: ['browser'], // Add your environment globals here
27
- }),
25
+ ...config(),
28
26
  {
29
27
  // Add custom rules here
30
28
  },
@@ -33,26 +31,31 @@ export default [
33
31
 
34
32
  #### Customizing the config
35
33
 
36
- The configuration comes with default settings that internally mirror the [neostandard](https://github.com/neostandard/neostandard/tree/main?tab=readme-ov-file#configuration-options) baseline. You can further customize it by passing an object to the `config` function:
37
-
38
- **Config settings defaults:**
39
-
40
- | Option | Type | Description | Default |
41
- | ---------- | ---------- | ----------------------------- | ------- |
42
- | ts | `boolean` | Enable TypeScript support | `true` |
43
- | noJsx | `boolean` | No jsx rules will be added | `true` |
44
- | noStyle | `boolean` | No style rules will be added | `true` |
45
- | semi | `boolean` | Use semicolons | `false` |
46
- | vue | `boolean` | Enable Vue.js support | `true` |
47
- | vueVersion | `2` or `3` | Specify the version of Vue.js | `3` |
48
- | vitest | `boolean` | Enable Vitest support | `true` |
34
+ The configuration composes [neostandard](https://github.com/neostandard/neostandard#configuration-options) with Vue, Vitest, Prettier, import checking, and project-specific rules. You can customize it by passing an object to `config`.
35
+
36
+ **Config defaults:**
37
+
38
+ | Option | Type | Description | Default |
39
+ | ---------- | ---------- | --------------------------------------------- | -------------------- |
40
+ | ts | `boolean` | Enable TypeScript support | `true` |
41
+ | noJsx | `boolean` | Disable JSX rules | `true` |
42
+ | noStyle | `boolean` | Disable style rules | `true` |
43
+ | semi | `boolean` | Use semicolons | `false` |
44
+ | vue | `boolean` | Enable Vue.js support | `true` |
45
+ | vueVersion | `2` or `3` | Specify the Vue.js version | `3` |
46
+ | vitest | `boolean` | Enable Vitest support | `true` |
47
+ | env | `string[]` | Additional global environments | Node.js and browser |
48
+ | files | `string[]` | Additional patterns for neostandard to lint | `**/*.vue` included |
49
+ | filesTs | `string[]` | Additional patterns for TypeScript linting | `[]` |
50
+ | globals | `string[]` or object | Additional global variables | None |
51
+ | ignores | `string[]` | Additional patterns to ignore | `[]` |
49
52
 
50
53
  **Example:**
51
54
 
52
55
  ```javascript
53
56
  config({
54
57
  ts: false,
55
- vue: true
58
+ vue: true,
56
59
  vueVersion: 3,
57
60
  vitest: false,
58
61
  })
@@ -70,7 +73,7 @@ export default prettierConfig
70
73
 
71
74
  ### package.json scripts
72
75
 
73
- Add the following ESLint commands to your `.package-json` for linting and autofixing:
76
+ Add the following ESLint commands to your `package.json` for linting and autofixing:
74
77
 
75
78
  ```json
76
79
  {
@@ -81,7 +84,7 @@ Add the following ESLint commands to your `.package-json` for linting and autofi
81
84
 
82
85
  ### VS Code settings
83
86
 
84
- Ad the following settings to your VS Code project settings for autofix on save:
87
+ Add the following settings to your VS Code project settings for autofix on save:
85
88
 
86
89
  `.vscode/settings.json`
87
90
 
@@ -102,7 +105,7 @@ Ad the following settings to your VS Code project settings for autofix on save:
102
105
 
103
106
  ## Features
104
107
 
105
- - Internally mirrors [neostandard](https://github.com/neostandard/neostandard)
108
+ - Built on [neostandard](https://github.com/neostandard/neostandard)
106
109
  - [Prettier](https://prettier.io) for code formatting
107
110
  - Plugins
108
111
  - [eslint-plugin-html](https://github.com/BenoitZugmeyer/eslint-plugin-html) for linting inline scripts contained in HTML files