Skip to content

Commit

Permalink
chore(deps): replace eslint and prettier by @biomejs/biome (#505)
Browse files Browse the repository at this point in the history
  • Loading branch information
wellwelwel authored Jul 2, 2024
1 parent df897d0 commit 6292cb4
Show file tree
Hide file tree
Showing 14 changed files with 348 additions and 1,514 deletions.
5 changes: 0 additions & 5 deletions .eslintignore

This file was deleted.

80 changes: 0 additions & 80 deletions .eslintrc.json

This file was deleted.

7 changes: 2 additions & 5 deletions .github/workflows/ci_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,5 @@ jobs:
- name: 📦 Installing Dependencies
run: npm ci

- name: 🤹🏻‍♀️ ESLint Check
run: npm run eslint:check

- name: 🤹🏻‍♀️ Prettier Check
run: npm run prettier:check
- name: 🤹🏻‍♀️ Biome Check
run: npm run lint:check
4 changes: 0 additions & 4 deletions .prettierignore

This file was deleted.

17 changes: 0 additions & 17 deletions .prettierrc

This file was deleted.

14 changes: 10 additions & 4 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
{
"deno.enable": false,
"editor.trimAutoWhitespace": true,
"editor.indentSize": 2,
"editor.tabSize": 2,
"editor.formatOnSave": true,
"files.trimTrailingWhitespace": true,
"editor.defaultFormatter": "biomejs.biome",
"editor.codeActionsOnSave": {
"source.fixAll": "explicit",
"source.fixAll.eslint": "explicit"
"source.fixAll": "explicit"
},
"eslint.validate": ["ts"],
"deno.enable": false
"[markdown]": {
"files.trimTrailingWhitespace": false,
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[yaml]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
}
120 changes: 120 additions & 0 deletions biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
{
"$schema": "https://biomejs.dev/schemas/1.8.2/schema.json",
"files": {
"include": ["**/**"],
"ignore": [
"node_modules",
"lib",
"ci",
"coverage",
"website",
"fixtures",
"benchmark"
]
},
"formatter": {
"enabled": true,
"indentWidth": 2,
"lineWidth": 80,
"indentStyle": "space",
"lineEnding": "lf"
},
"organizeImports": {
"enabled": false
},
"linter": {
"enabled": true,
"rules": {
"all": true,
"complexity": {
"all": true,
"noExcessiveCognitiveComplexity": "off"
},
"a11y": {
"all": true
},
"correctness": {
"all": true,
"noNodejsModules": "off"
},
"nursery": {
"all": true,
"useImportRestrictions": "off",
"noConsole": "off",
"noMisplacedAssertion": "off"
},
"performance": {
"all": true
},
"security": {
"all": true
},
"suspicious": {
"all": true,
"noEmptyBlockStatements": "off",
"noConsoleLog": "off"
},
"style": {
"all": true,
"noNonNullAssertion": "off",
"useNamingConvention": "off",
"useNodeAssertStrict": "off",
"noNamespaceImport": "off"
}
}
},
"javascript": {
"globals": ["BufferEncoding"],
"formatter": {
"enabled": true,
"semicolons": "always",
"quoteStyle": "single",
"quoteProperties": "asNeeded",
"trailingCommas": "es5",
"bracketSpacing": true,
"bracketSameLine": false,
"arrowParentheses": "always",
"lineEnding": "lf"
}
},
"json": {
"formatter": {
"enabled": true
}
},
"overrides": [
{
"include": ["test", "tools"],
"linter": {
"rules": {
"nursery": {
"useTopLevelRegex": "off"
},
"complexity": {
"useArrowFunction": "off"
}
}
}
},
{
"include": ["src/polyfills/**/**"],
"linter": {
"rules": {
"suspicious": {
"noExplicitAny": "off"
}
}
}
},
{
"include": ["src/modules/index.ts"],
"linter": {
"rules": {
"performance": {
"noBarrelFile": "off"
}
}
}
}
]
}
Loading

0 comments on commit 6292cb4

Please sign in to comment.