@kouts/eslint-config 1.1.0 → 1.2.0
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 +16 -11
- package/dist/index.cjs +4 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -1
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -25,30 +25,35 @@ export default [
|
|
|
25
25
|
...config(),
|
|
26
26
|
{
|
|
27
27
|
// Add custom rules here
|
|
28
|
-
}
|
|
28
|
+
},
|
|
29
29
|
]
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
#### Customizing the config
|
|
33
33
|
|
|
34
|
-
You can customize
|
|
35
|
-
|
|
36
|
-
```javascript
|
|
37
|
-
config({
|
|
38
|
-
ts: true,
|
|
39
|
-
vue: true
|
|
40
|
-
vueVersion: 3
|
|
41
|
-
})
|
|
42
|
-
```
|
|
34
|
+
The configuration comes with default settings that extend the [neostandard config](https://github.com/neostandard/neostandard/tree/main?tab=readme-ov-file#configuration-options) config. You can further customize it by passing an object to the `config` function:
|
|
43
35
|
|
|
44
|
-
**
|
|
36
|
+
**Config settings defaults:**
|
|
45
37
|
|
|
46
38
|
| Option | Type | Description | Default |
|
|
47
39
|
| ---------- | ---------- | ----------------------------- | ------- |
|
|
48
40
|
| ts | `boolean` | Enable TypeScript support | `true` |
|
|
41
|
+
| noJsx | `boolean` | No jsx rules will be added | `true` |
|
|
42
|
+
| noStyle | `boolean` | No style rules will be added | `true` |
|
|
43
|
+
| semi | `boolean` | No semicilons | `false` |
|
|
49
44
|
| vue | `boolean` | Enable Vue.js support | `true` |
|
|
50
45
|
| vueVersion | `2` or `3` | Specify the version of Vue.js | `3` |
|
|
51
46
|
|
|
47
|
+
**Example:**
|
|
48
|
+
|
|
49
|
+
```javascript
|
|
50
|
+
config({
|
|
51
|
+
ts: false,
|
|
52
|
+
vue: true
|
|
53
|
+
vueVersion: 3
|
|
54
|
+
})
|
|
55
|
+
```
|
|
56
|
+
|
|
52
57
|
### Prettier config
|
|
53
58
|
|
|
54
59
|
Create a `prettier.config.js` file with the following content:
|
package/dist/index.cjs
CHANGED
|
@@ -423,6 +423,9 @@ const vue = (options) => {
|
|
|
423
423
|
|
|
424
424
|
const config = (options) => {
|
|
425
425
|
const opts = {
|
|
426
|
+
noJsx: true,
|
|
427
|
+
noStyle: true,
|
|
428
|
+
semi: false,
|
|
426
429
|
ts: true,
|
|
427
430
|
vue: true,
|
|
428
431
|
vueVersion: 3,
|
|
@@ -449,7 +452,7 @@ const config = (options) => {
|
|
|
449
452
|
// TypeScript
|
|
450
453
|
...opts.ts ? typescript : [],
|
|
451
454
|
// Neostandard
|
|
452
|
-
...neostandard(
|
|
455
|
+
...neostandard(opts),
|
|
453
456
|
{
|
|
454
457
|
name: "kouts/neostandard-overrides",
|
|
455
458
|
rules: {
|
package/dist/index.d.cts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Linter } from 'eslint';
|
|
2
|
+
import { NeostandardOptions } from 'neostandard';
|
|
2
3
|
export { plugins } from 'neostandard';
|
|
3
4
|
|
|
4
5
|
type Options = {
|
|
5
|
-
ts?: boolean;
|
|
6
6
|
vue?: boolean;
|
|
7
7
|
vueVersion?: 2 | 3;
|
|
8
|
-
};
|
|
8
|
+
} & NeostandardOptions;
|
|
9
9
|
declare const config: (options?: Options) => Linter.Config<Linter.RulesRecord>[];
|
|
10
10
|
|
|
11
11
|
export { config };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Linter } from 'eslint';
|
|
2
|
+
import { NeostandardOptions } from 'neostandard';
|
|
2
3
|
export { plugins } from 'neostandard';
|
|
3
4
|
|
|
4
5
|
type Options = {
|
|
5
|
-
ts?: boolean;
|
|
6
6
|
vue?: boolean;
|
|
7
7
|
vueVersion?: 2 | 3;
|
|
8
|
-
};
|
|
8
|
+
} & NeostandardOptions;
|
|
9
9
|
declare const config: (options?: Options) => Linter.Config<Linter.RulesRecord>[];
|
|
10
10
|
|
|
11
11
|
export { config };
|
package/dist/index.js
CHANGED
|
@@ -422,6 +422,9 @@ const vue = (options) => {
|
|
|
422
422
|
|
|
423
423
|
const config = (options) => {
|
|
424
424
|
const opts = {
|
|
425
|
+
noJsx: true,
|
|
426
|
+
noStyle: true,
|
|
427
|
+
semi: false,
|
|
425
428
|
ts: true,
|
|
426
429
|
vue: true,
|
|
427
430
|
vueVersion: 3,
|
|
@@ -448,7 +451,7 @@ const config = (options) => {
|
|
|
448
451
|
// TypeScript
|
|
449
452
|
...opts.ts ? typescript : [],
|
|
450
453
|
// Neostandard
|
|
451
|
-
...neostandard(
|
|
454
|
+
...neostandard(opts),
|
|
452
455
|
{
|
|
453
456
|
name: "kouts/neostandard-overrides",
|
|
454
457
|
rules: {
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kouts/eslint-config",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.
|
|
5
|
-
"packageManager": "pnpm@9.7.
|
|
4
|
+
"version": "1.2.0",
|
|
5
|
+
"packageManager": "pnpm@9.7.1",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
|
8
8
|
},
|
|
9
|
-
"author": "
|
|
9
|
+
"author": "Giannis Koutsaftakis",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"bugs": {
|
|
12
12
|
"url": "https://github.com/kouts/eslint-config/issues"
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"prettier": "^3.3.3"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
|
-
"@types/node": "^22.
|
|
81
|
+
"@types/node": "^22.3.0",
|
|
82
82
|
"eslint": "^9.9.0",
|
|
83
83
|
"pkgroll": "^2.4.2",
|
|
84
84
|
"typescript": "^5.5.4"
|