chore: update biome configuration and enhance error handling in schema files

- Enabled useIgnoreFile in biome.json for better file management.
- Updated various correctness and style rules in biome.json to enforce stricter coding standards.
- Added new biome lint command in package.json for improved code quality checks.
- Refactored error handling in multiple schema files to use consistent error throwing patterns, enhancing readability and maintainability.
- Improved user authentication checks across various schemas to ensure proper access control.
This commit is contained in:
2024-12-08 21:01:26 +07:00
parent 10e20092ab
commit 45dca51990
17 changed files with 430 additions and 159 deletions

View File

@@ -3,7 +3,7 @@
"vcs": {
"enabled": false,
"clientKind": "git",
"useIgnoreFile": false
"useIgnoreFile": true
},
"files": {
"ignoreUnknown": false,
@@ -30,42 +30,42 @@
"complexity": {
"noUselessThisAlias": "error",
"noUselessTypeConstraint": "error",
"useArrowFunction": "off"
"useArrowFunction": "error"
},
"correctness": {
"noConstAssign": "off",
"noGlobalObjectCalls": "off",
"noInvalidBuiltinInstantiation": "off",
"noInvalidConstructorSuper": "off",
"noNewSymbol": "off",
"noSetterReturn": "off",
"noConstAssign": "error",
"noGlobalObjectCalls": "error",
"noInvalidBuiltinInstantiation": "error",
"noInvalidConstructorSuper": "error",
"noNewSymbol": "error",
"noSetterReturn": "error",
"noUndeclaredVariables": "off",
"noUnreachable": "off",
"noUnreachableSuper": "off",
"noUnreachable": "error",
"noUnreachableSuper": "error",
"noUnusedVariables": "error",
"useArrayLiterals": "off"
"useArrayLiterals": "error"
},
"style": {
"noArguments": "error",
"noNamespace": "error",
"noVar": "error",
"useAsConstAssertion": "error",
"useBlockStatements": "off",
"useBlockStatements": "error",
"useConst": "error"
},
"suspicious": {
"noDuplicateClassMembers": "off",
"noDuplicateObjectKeys": "off",
"noDuplicateParameters": "off",
"noDuplicateClassMembers": "error",
"noDuplicateObjectKeys": "error",
"noDuplicateParameters": "error",
"noExplicitAny": "error",
"noExtraNonNullAssertion": "error",
"noFunctionAssign": "off",
"noImportAssign": "off",
"noFunctionAssign": "error",
"noImportAssign": "error",
"noMisleadingInstantiator": "error",
"noRedeclare": "off",
"noRedeclare": "error",
"noUnsafeDeclarationMerging": "error",
"noUnsafeNegation": "off",
"useGetterReturn": "off",
"noUnsafeNegation": "error",
"useGetterReturn": "error",
"useNamespaceKeyword": "error"
}
},
@@ -80,7 +80,7 @@
"arrowParentheses": "always",
"bracketSameLine": false,
"quoteStyle": "single",
"attributePosition": "auto",
"attributePosition": "multiline",
"bracketSpacing": true
},
"parser": {