-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
.eslintrc.cjs
62 lines (61 loc) · 1.53 KB
/
.eslintrc.cjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
require("@rushstack/eslint-patch/modern-module-resolution");
module.exports = {
extends: [
"@vue/eslint-config-typescript/recommended",
"plugin:vue/vue3-recommended",
"plugin:import/recommended",
"plugin:import/typescript",
"prettier",
],
settings: {
"import/resolver": {
typescript: {},
},
},
ignorePatterns: "**/*.js",
parser: "vue-eslint-parser",
parserOptions: {
ecmaVersion: 13,
},
rules: {
"vue/attribute-hyphenation": 0,
"import/order": [
"error",
{
groups: [
"builtin",
"external",
"internal",
"parent",
"index",
"sibling",
"unknown",
"type",
],
alphabetize: { order: "asc" },
},
],
"import/no-restricted-paths": [
"warn", //TODO: errorにする
{
zones: [
{
target: "./src/(usecases|entities|adapter)",
from: "node_modules/vue",
message:
"フレームワーク非依存な層です。hooks層での実装を検討してください。",
},
{
target: "./src/!(entities)/**/*",
from: "./src/api/@types",
message: "APIの型定義はEntityに関数を作成して利用してください。",
},
],
},
],
// TODO: 以下のルールの無効化を見直す
"vue/multi-word-component-names": "off",
"vue/v-on-event-hyphenation": "off",
"vue/no-reserved-component-names": "off",
},
};