.oxlintrc.json 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. {
  2. "$schema": "https://raw.githubusercontent.com/nicolo-ribaudo/oxc-project.github.io/refs/heads/json-schema/src/public/.oxlintrc.schema.json",
  3. "options": {
  4. "typeAware": true
  5. },
  6. "categories": {
  7. "suspicious": "warn"
  8. },
  9. "rules": {
  10. "typescript/no-base-to-string": "warn",
  11. // Effect uses `function*` with Effect.gen/Effect.fnUntraced that don't always yield
  12. "require-yield": "off",
  13. // SolidJS uses `let ref: T | undefined` for JSX ref bindings assigned at runtime
  14. "no-unassigned-vars": "off",
  15. // SolidJS tracks reactive deps by reading properties inside createEffect
  16. "no-unused-expressions": "off",
  17. // Intentional control char matching (ANSI escapes, null byte sanitization)
  18. "no-control-regex": "off",
  19. // SST and plugin tools require triple-slash references
  20. "triple-slash-reference": "off",
  21. // Suspicious category: suppress noisy rules
  22. // Effect's nested function* closures inherently shadow outer scope
  23. "no-shadow": "off",
  24. // Namespace-heavy codebase makes this too noisy
  25. "unicorn/consistent-function-scoping": "off",
  26. // Opinionated — .sort()/.reverse() mutation is fine in this codebase
  27. "unicorn/no-array-sort": "off",
  28. "unicorn/no-array-reverse": "off",
  29. // Not relevant — this isn't a DOM event handler codebase
  30. "unicorn/prefer-add-event-listener": "off",
  31. // Bundler handles module resolution
  32. "unicorn/require-module-specifiers": "off",
  33. // postMessage target origin not relevant for this codebase
  34. "unicorn/require-post-message-target-origin": "off",
  35. // Side-effectful constructors are intentional in some places
  36. "no-new": "off",
  37. // Type-aware: catch unhandled promises
  38. "typescript/no-floating-promises": "warn",
  39. // Warn when spreading non-plain objects (Headers, class instances, etc.)
  40. "typescript/no-misused-spread": "warn"
  41. },
  42. "options": {
  43. "typeAware": true
  44. },
  45. "options": {
  46. "typeAware": true
  47. },
  48. "ignorePatterns": ["**/node_modules", "**/dist", "**/.build", "**/.sst", "**/*.d.ts", "**/sdk.gen.ts"]
  49. }