Skip to content

Commit

Permalink
chore: use shared eslint and prettier configurations
Browse files Browse the repository at this point in the history
  • Loading branch information
JuroUhlar committed Mar 20, 2024
1 parent e397e7e commit 31d6d84
Show file tree
Hide file tree
Showing 4 changed files with 115 additions and 120 deletions.
20 changes: 1 addition & 19 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,3 @@
module.exports = {
env: {
browser: true,
es6: true,
node: true,
},
extends: ['eslint:recommended', 'plugin:@typescript-eslint/eslint-recommended', 'plugin:prettier/recommended'],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
},
plugins: ['@typescript-eslint', 'prettier'],
rules: {
'linebreak-style': ['error', 'unix'],
'prefer-const': 'error',
'prettier/prettier': 'error',
'@typescript-eslint/no-unused-vars': ['error'],
curly: [2, 'all'],
},
extends: ['eslint:recommended', '@fingerprintjs/eslint-config-dx-team', 'plugin:prettier/recommended'],
}
12 changes: 1 addition & 11 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,11 +1 @@
{
"printWidth": 120,
"tabWidth": 2,
"useTabs": false,
"semi": false,
"singleQuote": true,
"trailingComma": "es5",
"bracketSpacing": true,
"bracketSameLine": false,
"arrowParens": "always"
}
"@fingerprintjs/prettier-config-dx-team"
11 changes: 5 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
"watch": "rimraf dist && rollup -c rollup.config.js -w",
"lint": "eslint --ext .js,.ts --ignore-path .gitignore --max-warnings 0 .",
"lint:fix": "pnpm lint --fix",
"prettier": "prettier src --check",
"prettier:fix": "yarn prettier --write",
"test": "jest",
"test:coverage": "jest --coverage",
"test:dts": "tsc --noEmit --isolatedModules dist/fp-pro-spa.d.ts",
Expand Down Expand Up @@ -56,23 +58,20 @@
"devDependencies": {
"@commitlint/cli": "^19.2.1",
"@commitlint/config-conventional": "^19.1.0",
"@fingerprintjs/eslint-config-dx-team": "^0.1.0",
"@fingerprintjs/prettier-config-dx-team": "^0.1.0",
"@fingerprintjs/tsconfig-dx-team": "^0.0.2",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-typescript": "^11.1.6",
"@types/jest": "^29.5.12",
"@types/node": "^20.11.30",
"@typescript-eslint/eslint-plugin": "^7.3.1",
"@typescript-eslint/parser": "^7.3.1",
"commitizen": "^4.3.0",
"conventional-changelog-conventionalcommits": "^7.0.2",
"cz-conventional-changelog": "^3.3.0",
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^5.1.3",
"husky": "^9.0.11",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"lint-staged": "^15.2.2",
"prettier": "^3.2.5",
"rimraf": "^5.0.5",
"rollup": "^4.13.0",
"rollup-plugin-dts": "^6.1.0",
Expand Down
Loading

0 comments on commit 31d6d84

Please sign in to comment.