mirror of
https://github.com/IT4Change/boilerplate-frontend.git
synced 2025-12-13 07:35:53 +00:00
enforce strict typings
This commit is contained in:
parent
89db9f8f4f
commit
690ad5fcde
5
.eslintignore
Normal file
5
.eslintignore
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
node_modules/
|
||||||
|
build/
|
||||||
|
coverage/
|
||||||
|
.storybook/
|
||||||
|
.vuepress/
|
||||||
@ -130,6 +130,28 @@
|
|||||||
"promise/no-multiple-resolved": "error"
|
"promise/no-multiple-resolved": "error"
|
||||||
},
|
},
|
||||||
"overrides": [
|
"overrides": [
|
||||||
|
{
|
||||||
|
"files": ["*.ts", "*.tsx"],
|
||||||
|
"parser": "@typescript-eslint/parser",
|
||||||
|
"parserOptions": {
|
||||||
|
"tsconfigRootDir": ".",
|
||||||
|
"project": ["./tsconfig.json", "**/tsconfig.json"],
|
||||||
|
"ecmaVersion": "latest",
|
||||||
|
"parser": "@typescript-eslint/parser",
|
||||||
|
"sourceType": "module"
|
||||||
|
},
|
||||||
|
"plugins": ["@typescript-eslint"],
|
||||||
|
"extends": [
|
||||||
|
"plugin:@typescript-eslint/recommended",
|
||||||
|
"plugin:@typescript-eslint/recommended-requiring-type-checking",
|
||||||
|
"plugin:@typescript-eslint/strict"
|
||||||
|
],
|
||||||
|
"rules": {
|
||||||
|
// allow explicitly defined dangling promises
|
||||||
|
"@typescript-eslint/no-floating-promises": ["error", { "ignoreVoid": true }],
|
||||||
|
"no-void": ["error", { "allowAsStatement": true }]
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"files": ["!*.json"],
|
"files": ["!*.json"],
|
||||||
"plugins": ["prettier"],
|
"plugins": ["prettier"],
|
||||||
|
|||||||
@ -45,7 +45,7 @@
|
|||||||
"storybook:build": "storybook build -o build/storybook",
|
"storybook:build": "storybook build -o build/storybook",
|
||||||
"storybook:test": "test-storybook",
|
"storybook:test": "test-storybook",
|
||||||
"test:lint": "npm run test:lint:eslint && npm run test:lint:remark && npm run test:lint:style && npm run test:lint:locales",
|
"test:lint": "npm run test:lint:eslint && npm run test:lint:remark && npm run test:lint:style && npm run test:lint:locales",
|
||||||
"test:lint:eslint": "eslint --ext .vue,.ts,.tsx,.js,.jsx,.json,.yml,.yaml --max-warnings 0 --ignore-path .gitignore .",
|
"test:lint:eslint": "eslint --ext .vue,.ts,.tsx,.js,.jsx,.json,.yml,.yaml --max-warnings 0 .",
|
||||||
"test:lint:locales": "scripts/locales/locales.sh src/locales",
|
"test:lint:locales": "scripts/locales/locales.sh src/locales",
|
||||||
"test:lint:remark": "remark . --quiet --frail",
|
"test:lint:remark": "remark . --quiet --frail",
|
||||||
"test:lint:style": "stylelint --max-warnings 0 --ignore-path .gitignore \"**/*.{css,scss,vue,vuex}\"",
|
"test:lint:style": "stylelint --max-warnings 0 --ignore-path .gitignore \"**/*.{css,scss,vue,vuex}\"",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user