Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

chore: configure oxlint using .oxlint.json (#6916)

Boshen48de982a6bb4
diff --git a/oxlint.json b/oxlint.json
index 2ff1e8a4c2..5576db37da 100644
--- a/oxlint.json
+++ b/oxlint.json
@@ -1,5 +1,11 @@
{
"rules": {
+ // allow
+ "import/named": "allow",
+ "no-await-in-loop": "allow",
+ // deny
+ "unicorn/prefer-array-some": "error",
+ "unicorn/no-useless-promise-resolve-reject": "error",
"import/no-cycle": [
"error",
{
diff --git a/package.json b/package.json
index 83fab801b0..7f859e1792 100644
--- a/package.json
+++ b/package.json
@@ -28,7 +28,7 @@
"lint:eslint:fix": "yarn lint:eslint --fix",
"lint:prettier": "prettier --ignore-unknown --cache --check .",
"lint:prettier:fix": "prettier --ignore-unknown --cache --write .",
- "lint:ox": "oxlint -c oxlint.json --import-plugin --deny-warnings -D correctness -D nursery -D prefer-array-some -D no-useless-promise-resolve-reject -D perf -A no-undef -A consistent-type-exports -A default -A named -A ban-ts-comment -A export -A no-unresolved -A no-default-export -A no-duplicates -A no-side-effects-in-initialization -A no-named-as-default -A getter-return -A no-barrel-file -A no-await-in-loop",
+ "lint:ox": "oxlint -c oxlint.json --deny-warnings --import-plugin -D correctness -D perf",
"lint": "yarn lint:eslint && yarn lint:prettier",
"lint:fix": "yarn lint:eslint:fix && yarn lint:prettier:fix",
"test": "vitest --run",