-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: migrage to biome fmt and linter
- Loading branch information
1 parent
423c73e
commit 0ebc43f
Showing
6 changed files
with
410 additions
and
330 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,102 @@ | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.9.4/schema.json", | ||
"vcs": { "enabled": false, "clientKind": "git", "useIgnoreFile": false }, | ||
"files": { "ignoreUnknown": false, "ignore": [] }, | ||
"formatter": { | ||
"enabled": true, | ||
"useEditorconfig": true, | ||
"formatWithErrors": false, | ||
"indentStyle": "space", | ||
"indentWidth": 4, | ||
"lineEnding": "lf", | ||
"lineWidth": 80, | ||
"attributePosition": "auto", | ||
"bracketSpacing": true | ||
}, | ||
"organizeImports": { "enabled": true }, | ||
"linter": { | ||
"enabled": true, | ||
"rules": { | ||
"recommended": false, | ||
"complexity": { | ||
"noBannedTypes": "error", | ||
"noUselessTypeConstraint": "error" | ||
}, | ||
"correctness": { | ||
"noPrecisionLoss": "error", | ||
"noUnusedVariables": "warn", | ||
"useArrayLiterals": "off" | ||
}, | ||
"style": { | ||
"noArguments": "off", | ||
"noInferrableTypes": "error", | ||
"noNamespace": "error", | ||
"noNonNullAssertion": "off", | ||
"useAsConstAssertion": "error", | ||
"useBlockStatements": "off" | ||
}, | ||
"suspicious": { | ||
"noEmptyBlockStatements": "error", | ||
"noExplicitAny": "warn", | ||
"noExtraNonNullAssertion": "error", | ||
"noMisleadingInstantiator": "error", | ||
"useNamespaceKeyword": "error" | ||
} | ||
}, | ||
"ignore": [ | ||
"**/.eslintrc.js", | ||
"**/dist/**", | ||
"**/dist-types/**", | ||
"**/examples/**", | ||
"**/*dist*" | ||
] | ||
}, | ||
"javascript": { | ||
"formatter": { | ||
"jsxQuoteStyle": "double", | ||
"quoteProperties": "asNeeded", | ||
"trailingCommas": "es5", | ||
"semicolons": "always", | ||
"arrowParentheses": "always", | ||
"bracketSameLine": false, | ||
"quoteStyle": "single", | ||
"attributePosition": "auto", | ||
"bracketSpacing": true | ||
} | ||
}, | ||
"overrides": [ | ||
{ | ||
"include": ["*.ts", "*.tsx", "*.mts", "*.cts"], | ||
"linter": { | ||
"rules": { | ||
"correctness": { | ||
"noConstAssign": "off", | ||
"noGlobalObjectCalls": "off", | ||
"noInvalidConstructorSuper": "off", | ||
"noNewSymbol": "off", | ||
"noSetterReturn": "off", | ||
"noUndeclaredVariables": "off", | ||
"noUnreachable": "off", | ||
"noUnreachableSuper": "off" | ||
}, | ||
"style": { | ||
"noArguments": "error", | ||
"noVar": "error", | ||
"useConst": "error" | ||
}, | ||
"suspicious": { | ||
"noDuplicateClassMembers": "off", | ||
"noDuplicateObjectKeys": "off", | ||
"noDuplicateParameters": "off", | ||
"noFunctionAssign": "off", | ||
"noImportAssign": "off", | ||
"noRedeclare": "off", | ||
"noUnsafeNegation": "off", | ||
"useGetterReturn": "off", | ||
"useValidTypeof": "off" | ||
} | ||
} | ||
} | ||
} | ||
] | ||
} |
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,10 +1,10 @@ | ||
module.exports = { | ||
'*.{js,css,json,md,yaml,yml,ts,tsx,cjs}': ['prettier --write'], | ||
'*.{js,css,json,md,yaml,yml,ts,tsx,cjs}': ['biome format --write'], | ||
'*.md': (filenames) => | ||
filenames.map((filename) => `'markdown-toc -i \"${filename}\"`), | ||
'*.ts': [ | ||
'npm run style:lint', | ||
'npm run style:prettier', | ||
'npm run style:fmt', | ||
() => 'tsc -p tsconfig.json --noEmit', | ||
], | ||
}; |
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,46 +1,41 @@ | ||
{ | ||
"name": "root", | ||
"private": true, | ||
"workspaces": [ | ||
"packages/*" | ||
], | ||
"devDependencies": { | ||
"@backstage/cli": "^0.26.11", | ||
"@commitlint/cli": "^17.1.2", | ||
"@commitlint/config-conventional": "^17.1.0", | ||
"@typescript-eslint/eslint-plugin": "^5.36.0", | ||
"@typescript-eslint/parser": "^5.36.0", | ||
"eslint": "^8.23.0", | ||
"eslint-config-prettier": "^8.5.0", | ||
"eslint-plugin-prettier": "^4.2.1", | ||
"husky": "^8.0.1", | ||
"is-ci": "^3.0.1", | ||
"lerna": "^8.1.7", | ||
"lint-staged": "^13.0.3", | ||
"markdown-toc": "^1.2.0", | ||
"prettier": "^2.7.1", | ||
"typescript": "~5.0.0" | ||
}, | ||
"engines": { | ||
"node": ">=18.0.0" | ||
}, | ||
"volta": { | ||
"node": "20.15.1" | ||
}, | ||
"scripts": { | ||
"type": "tsc --noEmit", | ||
"style:lint": "eslint packages --ext .ts", | ||
"style:lint-fix": "eslint packages --ext .ts --fix", | ||
"style:prettier": "prettier \"packages/**/*.ts\" --list-different --write", | ||
"build": "tsc && backstage-cli repo build --all", | ||
"bootstrap": "npx lerna bootstrap", | ||
"publish:ci": "lerna publish from-package --yes --pre-dist-tag alpha", | ||
"test": "lerna run test:ci", | ||
"start": "npx lerna --scope @immobiliarelabs/backstage-plugin-gitlab run start", | ||
"version:release": "lerna version --yes --conventional-commits --conventional-graduate --create-release github --message 'chore(release): publish'", | ||
"version:prerelease": "lerna version --yes --force-publish --conventional-commits --conventional-prerelease --create-release github --message 'chore(prerelease): publish'", | ||
"postinstall": "node prepare.js || echo 'Skipping prepare'", | ||
"prepare": "node prepare.js || echo 'Skipping prepare'" | ||
}, | ||
"packageManager": "[email protected]" | ||
"name": "root", | ||
"private": true, | ||
"workspaces": ["packages/*"], | ||
"devDependencies": { | ||
"@backstage/cli": "^0.26.11", | ||
"@biomejs/biome": "^1.9.4", | ||
"@commitlint/cli": "^17.1.2", | ||
"@commitlint/config-conventional": "^17.1.0", | ||
"@typescript-eslint/eslint-plugin": "^5.36.0", | ||
"@typescript-eslint/parser": "^5.36.0", | ||
"husky": "^8.0.1", | ||
"is-ci": "^3.0.1", | ||
"lerna": "^8.1.7", | ||
"lint-staged": "^13.0.3", | ||
"markdown-toc": "^1.2.0", | ||
"typescript": "~5.0.0" | ||
}, | ||
"engines": { | ||
"node": ">=18.0.0" | ||
}, | ||
"volta": { | ||
"node": "20.15.1" | ||
}, | ||
"scripts": { | ||
"type": "tsc --noEmit", | ||
"style:lint": "biome lint ./packages", | ||
"style:lint-fix": "biome lint --write ./packages", | ||
"style:fmt": "biome format --write ./packages", | ||
"build": "tsc && backstage-cli repo build --all", | ||
"bootstrap": "npx lerna bootstrap", | ||
"publish:ci": "lerna publish from-package --yes --pre-dist-tag alpha", | ||
"test": "lerna run test:ci", | ||
"start": "npx lerna --scope @immobiliarelabs/backstage-plugin-gitlab run start", | ||
"version:release": "lerna version --yes --conventional-commits --conventional-graduate --create-release github --message 'chore(release): publish'", | ||
"version:prerelease": "lerna version --yes --force-publish --conventional-commits --conventional-prerelease --create-release github --message 'chore(prerelease): publish'", | ||
"postinstall": "node prepare.js || echo 'Skipping prepare'", | ||
"prepare": "node prepare.js || echo 'Skipping prepare'" | ||
}, | ||
"packageManager": "[email protected]" | ||
} |
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,75 +1,72 @@ | ||
{ | ||
"name": "@immobiliarelabs/backstage-plugin-gitlab-backend", | ||
"version": "6.7.0", | ||
"name": "@immobiliarelabs/backstage-plugin-gitlab-backend", | ||
"version": "6.7.0", | ||
"main": "dist/index.cjs.js", | ||
"types": "dist/index.d.ts", | ||
"license": "Apache-2.0", | ||
"publishConfig": { | ||
"access": "public", | ||
"main": "dist/index.cjs.js", | ||
"types": "dist/index.d.ts", | ||
"license": "Apache-2.0", | ||
"publishConfig": { | ||
"access": "public", | ||
"main": "dist/index.cjs.js", | ||
"types": "dist/index.d.ts" | ||
}, | ||
"backstage": { | ||
"role": "backend-plugin", | ||
"pluginId": "gitlab", | ||
"pluginPackages": [ | ||
"@immobiliarelabs/backstage-plugin-gitlab", | ||
"@immobiliarelabs/backstage-plugin-gitlab-backend" | ||
] | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/immobiliare/backstage-plugin-gitlab" | ||
}, | ||
"keywords": [ | ||
"backstage", | ||
"gitlab", | ||
"ci/cd", | ||
"immobiliare", | ||
"immobiliarelabs", | ||
"backend" | ||
], | ||
"scripts": { | ||
"start": "backstage-cli package start", | ||
"types": "tsc", | ||
"build": "backstage-cli package build", | ||
"lint": "backstage-cli package lint", | ||
"test": "backstage-cli package test", | ||
"test:ci": "backstage-cli package test --watch false", | ||
"clean": "backstage-cli package clean", | ||
"prepack": "backstage-cli package prepack", | ||
"postpack": "backstage-cli package postpack" | ||
}, | ||
"dependencies": { | ||
"@backstage/backend-common": "^0.23.3", | ||
"@backstage/backend-plugin-api": "^0.7.0", | ||
"@backstage/config": "^1.2.0", | ||
"@backstage/integration": "^1.13.0", | ||
"body-parser": "^1.20.2", | ||
"express": "^4.17.3", | ||
"express-promise-router": "^4.1.0", | ||
"http-proxy-middleware": "^2.0.6", | ||
"winston": "^3.2.1", | ||
"yn": "^4.0.0" | ||
}, | ||
"devDependencies": { | ||
"@backstage/backend-test-utils": "^0.4.4", | ||
"@backstage/catalog-model": "^1.5.0", | ||
"@backstage/cli": "^0.26.11", | ||
"@backstage/plugin-catalog-common": "^1.0.25", | ||
"@backstage/plugin-catalog-node": "^1.12.4", | ||
"@types/express": "^4.17.21", | ||
"@types/supertest": "^2.0.12", | ||
"msw": "^1.0.0", | ||
"supertest": "^6.2.4" | ||
}, | ||
"volta": { | ||
"node": "18.12.1", | ||
"yarn": "1.22.19" | ||
}, | ||
"files": [ | ||
"dist", | ||
"config.d.ts" | ||
], | ||
"configSchema": "config.d.ts" | ||
"types": "dist/index.d.ts" | ||
}, | ||
"backstage": { | ||
"role": "backend-plugin", | ||
"pluginId": "gitlab", | ||
"pluginPackages": [ | ||
"@immobiliarelabs/backstage-plugin-gitlab", | ||
"@immobiliarelabs/backstage-plugin-gitlab-backend" | ||
] | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/immobiliare/backstage-plugin-gitlab" | ||
}, | ||
"keywords": [ | ||
"backstage", | ||
"gitlab", | ||
"ci/cd", | ||
"immobiliare", | ||
"immobiliarelabs", | ||
"backend" | ||
], | ||
"scripts": { | ||
"start": "backstage-cli package start", | ||
"types": "tsc", | ||
"build": "backstage-cli package build", | ||
"lint": "backstage-cli package lint", | ||
"test": "backstage-cli package test", | ||
"test:ci": "backstage-cli package test --watch false", | ||
"clean": "backstage-cli package clean", | ||
"prepack": "backstage-cli package prepack", | ||
"postpack": "backstage-cli package postpack" | ||
}, | ||
"dependencies": { | ||
"@backstage/backend-common": "^0.23.3", | ||
"@backstage/backend-plugin-api": "^0.7.0", | ||
"@backstage/config": "^1.2.0", | ||
"@backstage/integration": "^1.13.0", | ||
"body-parser": "^1.20.2", | ||
"express": "^4.17.3", | ||
"express-promise-router": "^4.1.0", | ||
"http-proxy-middleware": "^2.0.6", | ||
"winston": "^3.2.1", | ||
"yn": "^4.0.0" | ||
}, | ||
"devDependencies": { | ||
"@backstage/backend-test-utils": "^0.4.4", | ||
"@backstage/catalog-model": "^1.5.0", | ||
"@backstage/cli": "^0.26.11", | ||
"@backstage/plugin-catalog-common": "^1.0.25", | ||
"@backstage/plugin-catalog-node": "^1.12.4", | ||
"@types/express": "^4.17.21", | ||
"@types/supertest": "^2.0.12", | ||
"msw": "^1.0.0", | ||
"supertest": "^6.2.4" | ||
}, | ||
"volta": { | ||
"node": "18.12.1", | ||
"yarn": "1.22.19" | ||
}, | ||
"files": ["dist", "config.d.ts"], | ||
"configSchema": "config.d.ts" | ||
} |
Oops, something went wrong.