@hyeon/linter 7.3.4 → 7.3.6
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 +3 -14
- package/package.json +1 -1
- package/src/prettier.mjs +1 -0
- package/src/typescript.mjs +16 -4
package/README.md
CHANGED
|
@@ -16,31 +16,20 @@ export default [
|
|
|
16
16
|
]
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
### NestJS
|
|
19
|
+
### TypeScript (NestJS 지원 포함)
|
|
20
20
|
|
|
21
|
-
NestJS
|
|
21
|
+
TypeScript 설정은 NestJS 데코레이터를 포함한 모든 TypeScript 기능을 지원합니다:
|
|
22
22
|
|
|
23
23
|
```js
|
|
24
24
|
// eslint.config.js
|
|
25
25
|
import hyeonLinter from '@hyeon/linter'
|
|
26
26
|
|
|
27
27
|
export default [
|
|
28
|
-
...hyeonLinter.
|
|
28
|
+
...hyeonLinter.typescript,
|
|
29
29
|
]
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
-
또는 직접 import:
|
|
33
|
-
|
|
34
|
-
```js
|
|
35
|
-
// eslint.config.js
|
|
36
|
-
import hyeonNestjsConfig from '@hyeon/linter/nestjs'
|
|
37
|
-
|
|
38
|
-
export default [
|
|
39
|
-
...hyeonNestjsConfig,
|
|
40
|
-
]
|
|
41
|
-
```
|
|
42
32
|
|
|
43
|
-
**주의**: NestJS 설정은 TypeScript 설정을 이미 포함하고 있으므로, `typescript` 설정을 별도로 추가할 필요가 없습니다.
|
|
44
33
|
|
|
45
34
|
## vite
|
|
46
35
|
|
package/package.json
CHANGED
package/src/prettier.mjs
CHANGED
|
@@ -21,6 +21,7 @@ export default [
|
|
|
21
21
|
"importOrder": ["^[^.](.*)$", "^[.]{1,2}/.*$"],
|
|
22
22
|
"importOrderSeparation": false,
|
|
23
23
|
"importOrderSortSpecifiers": true,
|
|
24
|
+
"importOrderParserPlugins": ["typescript", "decorators-legacy", "jsx", "classProperties"],
|
|
24
25
|
}],
|
|
25
26
|
'arrow-body-style': ['error', 'as-needed'],
|
|
26
27
|
'prefer-arrow-callback': 'error',
|
package/src/typescript.mjs
CHANGED
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
import js from '@eslint/js';
|
|
2
2
|
import tseslint from 'typescript-eslint'
|
|
3
|
+
import eslintConfigPrettier from "eslint-config-prettier";
|
|
3
4
|
|
|
4
5
|
export default tseslint.config(
|
|
6
|
+
{
|
|
7
|
+
ignores: ['**/node_modules/**', '**/dist/**', '**/.turbo/**', '**/coverage/**'],
|
|
8
|
+
},
|
|
5
9
|
js.configs.recommended,
|
|
10
|
+
...tseslint.configs.recommended,
|
|
11
|
+
eslintConfigPrettier,
|
|
6
12
|
{
|
|
7
|
-
|
|
13
|
+
files: ['**/*.ts', '**/*.tsx', '**/*.mts', '**/*.cts'],
|
|
8
14
|
languageOptions: {
|
|
9
15
|
parser: tseslint.parser,
|
|
10
16
|
parserOptions: {
|
|
@@ -15,11 +21,17 @@ export default tseslint.config(
|
|
|
15
21
|
},
|
|
16
22
|
},
|
|
17
23
|
},
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
ignores: ['node_modules/', 'dist/'],
|
|
21
24
|
rules: {
|
|
22
25
|
"react/prop-types": "off",
|
|
26
|
+
"@typescript-eslint/no-explicit-any": "off",
|
|
27
|
+
"@typescript-eslint/no-unused-vars": ["error", {
|
|
28
|
+
argsIgnorePattern: "^_",
|
|
29
|
+
varsIgnorePattern: "^_",
|
|
30
|
+
}],
|
|
31
|
+
'@typescript-eslint/interface-name-prefix': 'off',
|
|
32
|
+
'@typescript-eslint/explicit-function-return-type': 'off',
|
|
33
|
+
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
|
34
|
+
'@typescript-eslint/no-non-null-assertion': 'off',
|
|
23
35
|
}
|
|
24
36
|
},
|
|
25
37
|
);
|