Skip to content

Commit

Permalink
chore: migrate from eslint to biome
Browse files Browse the repository at this point in the history
  • Loading branch information
ayZagen committed Jan 17, 2025
1 parent 5755a1b commit 037f37b
Show file tree
Hide file tree
Showing 108 changed files with 7,821 additions and 8,224 deletions.
4 changes: 1 addition & 3 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
{
"presets": [
["@babel/preset-env"]
]
"presets": [["@babel/preset-env"]]
}
8 changes: 0 additions & 8 deletions .eslintignore

This file was deleted.

127 changes: 0 additions & 127 deletions .eslintrc.js

This file was deleted.

24 changes: 12 additions & 12 deletions .release-it.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
module.exports = {
hooks:{
hooks: {
"before:init": ["npm run lint", "npm test"],
"after:bump": ["npm run docs", "npm run build"],
},
git: {
"commitMessage": "chore: release v${version}",
"requireCleanWorkingDir": true,
"tagAnnotation": "Release v${version}",
"tagName": "v${version}"
commitMessage: "chore: release v${version}",
requireCleanWorkingDir: true,
tagAnnotation: "Release v${version}",
tagName: "v${version}",
},
github: {
"release": true,
"draft": true,
"releaseName": "v${version}"
release: true,
draft: true,
releaseName: "v${version}",
},
plugins: {
"@release-it/conventional-changelog": {
"preset": "angular",
"infile": "CHANGELOG.md"
}
}
preset: "angular",
infile: "CHANGELOG.md",
},
},
}
17 changes: 5 additions & 12 deletions api-extractor.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,33 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
"mainEntryPointFilePath": "<projectFolder>/types/index.d.ts",
"bundledPackages": [ ],
"compiler": {
},
"bundledPackages": [],
"compiler": {},
"newlineKind": "lf",
"apiReport": {
"enabled": false,
// "reportFileName": "<unscopedPackageName>.api.md",
"reportFolder": "<projectFolder>/docs/"
},
"docModel": {
"enabled": true
// "apiJsonFilePath": "<projectFolder>/temp/<unscopedPackageName>.api.json"
},
"dtsRollup": {
"enabled": true,
untrimmedFilePath: "<projectFolder>/dist/plusauth-web.d.ts",
publicTrimmedFilePath: "<projectFolder>/dist/plusauth-web.d.ts"
"untrimmedFilePath": "<projectFolder>/dist/plusauth-web.d.ts",
"publicTrimmedFilePath": "<projectFolder>/dist/plusauth-web.d.ts"
},
"tsdocMetadata": {
enabled: false
"enabled": false
},
"messages": {
"compilerMessageReporting": {
"default": {
"logLevel": "warning"
// "addToApiReportFile": false
}
},
"extractorMessageReporting": {
"default": {
"logLevel": "warning"
// "addToApiReportFile": false
},
"ae-missing-release-tag": {
"logLevel": "none"
Expand All @@ -41,9 +36,7 @@
"tsdocMessageReporting": {
"default": {
"logLevel": "warning"
// "addToApiReportFile": false
}
}
}

}
146 changes: 146 additions & 0 deletions biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
{
"$schema": "https://biomejs.dev/schemas/1.9.4/schema.json",
"vcs": {
"enabled": true,
"defaultBranch": "main",
"useIgnoreFile": true,
"clientKind": "git"
},
"files": {
"ignoreUnknown": true,
"ignore": [
".nx/",
"node_modules",
"**/*/node_modules",
"dist/",
"docs/",
"**/*/dist",
"*.timestamp-*",
"components.d.ts"
]
},
"organizeImports": {
"enabled": true
},
"javascript": {
"formatter": {
"arrowParentheses": "always",
"bracketSameLine": false,
"bracketSpacing": true,
"jsxQuoteStyle": "double",
"quoteProperties": "asNeeded",
"semicolons": "asNeeded",
"trailingCommas": "all"
}
},
"formatter": {
"enabled": true,
"formatWithErrors": false,
"attributePosition": "multiline",
"indentStyle": "space",
"indentWidth": 2,
"lineWidth": 100,
"lineEnding": "lf"
},
"linter": {
"enabled": true,
"ignore": ["*.d.ts"],
"rules": {
"a11y": {
"useKeyWithClickEvents": "off"
},
"recommended": true,
"performance": {
"noDelete": "off"
},
"correctness": {
"noUnknownFunction": {
"level": "off"
},
"noUnusedImports": {
"level": "error"
},
"noSwitchDeclarations": {
"level": "error",
"fix": "safe"
}
},
"complexity": {
"noBannedTypes": "off",
"noForEach": "off",
"useOptionalChain": {
"level": "error",
"fix": "safe"
},
"useLiteralKeys": {
"level": "info"
}
},
"style": {
"noArguments": "off",
"noNonNullAssertion": "off",
"noParameterAssign": "off",
"noUnusedTemplateLiteral": "off",
"noUselessElse": {
"level": "error",
"fix": "safe"
},
"useImportType": "error",
"useSingleVarDeclarator": {
"level": "error",
"fix": "safe"
},
"useNodejsImportProtocol": {
"level": "error",
"fix": "safe"
},
"useTemplate": {
"level": "error",
"fix": "safe"
}
},
"suspicious": {
"noAsyncPromiseExecutor": "off",
"noPrototypeBuiltins": "off",
"noAssignInExpressions": "off",
"noExplicitAny": "off",
"noConfusingVoidType": "off",
"noGlobalIsFinite": {
"level": "error",
"fix": "safe"
},
"noGlobalIsNan": {
"level": "error",
"fix": "safe"
},
"noImplicitAnyLet": "off"
}
}
},
"overrides": [
{
"include": ["test"],
"linter": {
"rules": {
"suspicious": {
"noImportAssign": "off"
}
}
}
},
{
"include": ["*.vue"],
"linter": {
"rules": {
"style": {
"useImportType": "off",
"useConst": "off"
},
"correctness": {
"noUnusedImports": "off"
}
}
}
}
]
}
Loading

0 comments on commit 037f37b

Please sign in to comment.