Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
181 changes: 181 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": [
"unicorn"
],
"categories": {
"correctness": "off"
},
"env": {
"builtin": true
},
"ignorePatterns": [
"dist/",
"tests/env/",
"coverage/",
"playgrounds/",
"docs/"
],
"rules": {
"for-direction": "error",
"no-async-promise-executor": "error",
"no-case-declarations": "error",
"no-class-assign": "error",
"no-compare-neg-zero": "error",
"no-cond-assign": "error",
"no-const-assign": "error",
"no-constant-binary-expression": "error",
"no-constant-condition": "error",
"no-control-regex": "error",
"no-debugger": "error",
"no-delete-var": "error",
"no-dupe-class-members": "error",
"no-dupe-else-if": "error",
"no-dupe-keys": "error",
"no-duplicate-case": "error",
"no-empty": "error",
"no-empty-character-class": "error",
"no-empty-pattern": "error",
"no-empty-static-block": "error",
"no-ex-assign": "error",
"no-extra-boolean-cast": "error",
"no-fallthrough": "error",
"no-func-assign": "error",
"no-global-assign": "error",
"no-import-assign": "error",
"no-invalid-regexp": "error",
"no-irregular-whitespace": "error",
"no-loss-of-precision": "error",
"no-new-native-nonconstructor": "error",
"no-nonoctal-decimal-escape": "error",
"no-obj-calls": "error",
"no-prototype-builtins": "error",
"no-redeclare": "error",
"no-regex-spaces": "error",
"no-self-assign": "error",
"no-setter-return": "error",
"no-shadow-restricted-names": "error",
"no-sparse-arrays": "error",
"no-this-before-super": "error",
"no-unexpected-multiline": "off",
"no-unsafe-finally": "error",
"no-unsafe-negation": "error",
"no-unsafe-optional-chaining": "error",
"no-unused-labels": "error",
"no-unused-private-class-members": "error",
"no-unused-vars": "error",
"no-useless-backreference": "error",
"no-useless-catch": "error",
"no-useless-escape": "error",
"no-with": "error",
"require-yield": "error",
"use-isnan": "error",
"valid-typeof": "error",
"curly": "off",
"unicorn/empty-brace-spaces": "off",
"unicorn/no-nested-ternary": "off",
"unicorn/number-literal-case": "off"
},
"overrides": [
{
"files": [
"**/*.js"
],
"env": {
"commonjs": true,
"node": true,
"shared-node-browser": true
}
},
{
"files": [
"**/*.ts"
],
"rules": {
"no-class-assign": "off",
"no-const-assign": "off",
"no-dupe-class-members": "off",
"no-dupe-keys": "off",
"no-func-assign": "off",
"no-import-assign": "off",
"no-new-native-nonconstructor": "off",
"no-obj-calls": "off",
"no-redeclare": "off",
"no-setter-return": "off",
"no-this-before-super": "off",
"no-unsafe-negation": "off",
"no-var": "error",
"no-with": "off",
"prefer-rest-params": "error",
"prefer-spread": "error"
}
},
{
"files": [
"**/*.ts"
],
"rules": {
"@typescript-eslint/ban-ts-comment": "error",
"no-array-constructor": "error",
"@typescript-eslint/no-duplicate-enum-values": "error",
"@typescript-eslint/no-empty-object-type": "error",
"@typescript-eslint/no-explicit-any": "error",
"@typescript-eslint/no-extra-non-null-assertion": "error",
"@typescript-eslint/no-misused-new": "error",
"@typescript-eslint/no-namespace": "error",
"@typescript-eslint/no-non-null-asserted-optional-chain": "error",
"@typescript-eslint/no-require-imports": "error",
"@typescript-eslint/no-this-alias": "error",
"@typescript-eslint/no-unnecessary-type-constraint": "error",
"@typescript-eslint/no-unsafe-declaration-merging": "error",
"@typescript-eslint/no-unsafe-function-type": "error",
"no-unused-expressions": "error",
"@typescript-eslint/no-wrapper-object-types": "error",
"no-throw-literal": "off",
"@typescript-eslint/prefer-as-const": "error",
"@typescript-eslint/prefer-namespace-keyword": "error",
"prefer-promise-reject-errors": "off",
"require-await": "off",
"@typescript-eslint/triple-slash-reference": "error"
},
"plugins": [
"typescript"
]
},
{
"files": [
"**/*.ts"
],
"rules": {
"no-unused-vars": [
"error",
{
"args": "all",
"argsIgnorePattern": "^_",
"varsIgnorePattern": "^_"
}
]
},
"plugins": [
"typescript"
]
},
{
"files": [
"tests/**/*.test.ts"
],
"rules": {
"vitest/expect-expect": "error",
"vitest/no-identical-title": "error",
"vitest/no-commented-out-tests": "error",
"vitest/valid-expect": "error",
"vitest/valid-describe-callback": "error",
"vitest/require-local-test-context-for-concurrent-snapshots": "error",
"vitest/no-import-node-test": "error"
},
"plugins": [
"vitest"
]
}
]
}
47 changes: 0 additions & 47 deletions eslint.config.js

This file was deleted.

2 changes: 1 addition & 1 deletion lint-staged.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
* @see {@link https://github.com/lint-staged/lint-staged?tab=readme-ov-file#configuration}
* @see {@link https://github.com/lint-staged/lint-staged?tab=readme-ov-file#using-js-configuration-files}
*/
export default { "*.{js,ts}": ["prettier -w", "eslint"] };
export default { "*.{js,ts}": ["prettier -w", "oxlint"] };
18 changes: 6 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
"test:env:nitro-app": "yarn build && yarn --cwd tests/env/nitro-app test",
"fmt": "prettier -c ./**/*.{js,ts}",
"fmt:fix": "prettier -w ./**/*.{js,ts}",
"lint": "eslint",
"lint:fix": "eslint --fix",
"lint": "oxlint",
"lint:fix": "oxlint --fix",
"style": "yarn fmt && yarn lint",
"style:fix": "yarn fmt:fix && yarn lint:fix",
"prepare": "husky"
Expand All @@ -69,23 +69,17 @@
"CONTRIBUTING.md"
],
"devDependencies": {
"@eslint/js": "^9.23.0",
"@vitest/coverage-v8": "^3.1.1",
"@types/node": "^22.15.29",
"@typescript-eslint/utils": "^8.29.0",
"@vitest/eslint-plugin": "^1.2.1",
"eslint": "^9.28.0",
"eslint-config-prettier": "^10.1.2",
"eslint-plugin-tsdoc": "^0.4.0",
"typescript": "^5.8.3",
"vite": "^6.3.5",
"@vitest/coverage-v8": "^3.1.1",
"globals": "^16.2.0",
"husky": "^9.1.7",
"lint-staged": "16.1.0",
"oxlint": "^1.0.0",
"prettier": "^3.5.3",
"prettier-plugin-jsdoc": "^1.3.2",
"typedoc": "^0.28.5",
"typescript-eslint": "^8.33.0",
"typescript": "^5.8.3",
"vite": "^6.3.5",
"vitest": "^3.1.1"
},
"packageManager": "[email protected]"
Expand Down
2 changes: 1 addition & 1 deletion tests/pagination.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {
import {
expect,
test,
describe,
Expand Down
Loading
Loading