-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: optimize project configuration (#3)
- Loading branch information
1 parent
ba77625
commit bb2a1f0
Showing
17 changed files
with
6,853 additions
and
450 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
**/node_modules/* | ||
.dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
{ | ||
"root": true, | ||
"env": { | ||
"es6": true, | ||
"node": true, | ||
"shared-node-browser": true | ||
}, | ||
"parser": "@typescript-eslint/parser", | ||
"parserOptions": { | ||
"sourceType": "module" | ||
}, | ||
"extends": [ | ||
"plugin:prettier/recommended", | ||
"prettier" | ||
], | ||
"plugins": [ | ||
"@typescript-eslint/eslint-plugin", | ||
"import", | ||
"jest" | ||
], | ||
"overrides": [ | ||
{ | ||
"files": [ | ||
"*.ts", | ||
"*.tsx" | ||
], | ||
"parser": "@typescript-eslint/parser", | ||
"plugins": [ | ||
"@typescript-eslint/eslint-plugin" | ||
], | ||
"rules": { | ||
"@typescript-eslint/no-unused-vars": [ | ||
"warn", | ||
{ | ||
"argsIgnorePattern": "^_", | ||
"destructuredArrayIgnorePattern": "^_" | ||
} | ||
], | ||
"no-unused-vars": "off", | ||
"no-shadow": "off", | ||
"@typescript-eslint/no-shadow": 1, | ||
"no-undef": "off", | ||
"func-call-spacing": "off", | ||
"@typescript-eslint/func-call-spacing": 1 | ||
} | ||
}, | ||
{ | ||
"files": [ | ||
"*.{spec,test}.{js,ts,tsx}", | ||
"**/__{mocks,tests}__/**/*.{js,ts,tsx}" | ||
], | ||
"env": { | ||
"jest": true, | ||
"jest/globals": true | ||
}, | ||
"rules": { | ||
"react-native/no-inline-styles": 0, | ||
"quotes": [ | ||
1, | ||
"single", | ||
{ | ||
"avoidEscape": true, | ||
"allowTemplateLiterals": true | ||
} | ||
] | ||
} | ||
} | ||
], | ||
"globals": { | ||
"define": false, | ||
"obj_attrib": false, | ||
"info": false, | ||
"NodeJS": false, | ||
"window": false, | ||
"alert": false, | ||
"document": false, | ||
"HTMLElement": false, | ||
"HTMLDivElement": false, | ||
"WebGL2RenderingContext": false, | ||
"WebGLTexture": false, | ||
"HTMLCanvasElement": false, | ||
"ResizeObserver": false, | ||
"name": false, | ||
"Element": false | ||
}, | ||
"rules": { | ||
"prettier/prettier": [ | ||
"error", | ||
{ | ||
"quoteProps": "consistent", | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "es5", | ||
"useTabs": false | ||
} | ||
], | ||
"no-unused-vars": "off", | ||
"@typescript-eslint/no-unused-vars": "warn", | ||
"import/order": [ | ||
"error", | ||
{ | ||
"newlines-between": "always-and-inside-groups", | ||
"alphabetize": { | ||
"order": "asc", | ||
"orderImportKind": "asc" | ||
} | ||
} | ||
], | ||
"sort-imports": [ | ||
"error", | ||
{ | ||
"ignoreDeclarationSort": true, | ||
"ignoreMemberSort": false | ||
} | ||
], | ||
"jest/no-disabled-tests": 1, | ||
"jest/no-focused-tests": 1, | ||
"jest/no-identical-title": 1, | ||
"jest/valid-expect": 1 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
.ccls-cache/ | ||
node_modules/ | ||
src/**/*.js | ||
package-lock.json | ||
dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
**/node_modules/* | ||
.dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"quoteProps": "consistent", | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "es5", | ||
"useTabs": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module.exports = { | ||
coverageDirectory: 'coverage', | ||
preset: 'ts-jest', | ||
testEnvironment: 'node', | ||
testRegex: '/__tests__/.*\\.(test|spec)\\.[jt]sx?$', | ||
}; |
Oops, something went wrong.