-
-
Notifications
You must be signed in to change notification settings - Fork 662
Expand file tree
/
Copy pathbiome.jsonc
More file actions
162 lines (162 loc) · 5.48 KB
/
biome.jsonc
File metadata and controls
162 lines (162 loc) · 5.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
{
"$schema": "https://biomejs.dev/schemas/1.6.2/schema.json",
"files": {
"ignore": [
"packages/ui/src/components/*.tsx",
"packages/ui/src/components/*.ts",
"apps/dashboard/src/scripts/*.ts",
"packages/proto/gen",
".devbox"
]
},
"linter": {
"enabled": true,
"rules": {
"recommended": true,
"suspicious": {
"noArrayIndexKey": "off"
},
"performance": {
"noAccumulatingSpread": "warn"
},
"complexity": {
"noForEach": "off"
},
"a11y": {
"noSvgWithoutTitle": "off",
"useKeyWithClickEvents": "off"
},
"correctness": {
"noUnusedVariables": "warn",
"noUnusedImports": "error",
"noSwitchDeclarations": "off"
},
"nursery": {
"useSortedClasses": "warn"
}
},
"ignore": [
"node_modules",
".next",
"dist",
".wrangler",
".react-email",
".content-collections",
"meta",
"*.astro",
".astro"
]
},
"formatter": {
"indentStyle": "space",
"indentWidth": 2,
"enabled": true,
"lineWidth": 80,
"ignore": [
"node_modules",
".next",
"dist",
".nuxt",
".wrangler",
".react-email",
".content-collections",
"meta",
"*.astro",
".astro"
]
},
"organizeImports": {
"enabled": true,
"ignore": [
"node_modules",
".next",
"dist",
".nuxt",
".wrangler",
".react-email",
".content-collections",
"*.astro",
".astro"
]
},
// Overrides: scope the `@openstatus/db` / drizzle import ban to files that
// have been migrated onto `@openstatus/services`. Grown one domain per
// migration PR.
//
// Still outside the scope (each is its own follow-up):
// - `packages/api/src/router/statusPage.ts` — public viewer endpoints
// (~1280 lines) run under `publicProcedure` without an authed
// `ServiceContext`.
// - `packages/api/src/router/{member,integration,monitorTag,
// pageSubscriber,privateLocation,checker,feedback,stripe,tinybird,
// email}.ts` — small domains not yet lifted into services.
// - `apps/server/src/routes/rpc/handlers/monitor/**` — Connect monitor
// handler (~880 lines, 6 jobType-specific methods).
// - `apps/server/src/routes/rpc/handlers/status-page/**` — 13 of 18
// methods (components / groups / subscribers / viewer) still use db;
// page CRUD is migrated but the file imports db for the rest.
// - `apps/server/src/routes/v1/**` — the public HTTP API surface;
// entirely unmigrated, intended to ride on top of services later.
// - `apps/server/src/routes/slack/**` except `interactions.ts` — tools,
// handler, oauth, workspace-resolver still use db.
// - `apps/server/src/routes/public/**` — public-facing HTTP routes.
//
// When those migrate, their paths get added here. The final consolidation
// (broadening to `router/**` + dropping the db dep from `packages/api` +
// `apps/server`) comes after.
"overrides": [
{
"include": [
"packages/api/src/router/statusReport.ts",
"packages/api/src/router/maintenance.ts",
"packages/api/src/router/incident.ts",
"packages/api/src/router/monitor.ts",
"packages/api/src/router/pageComponent.ts",
"packages/api/src/router/page.ts",
"packages/api/src/router/workspace.ts",
"packages/api/src/router/user.ts",
"packages/api/src/router/invitation.ts",
"packages/api/src/router/apiKey.ts",
"packages/api/src/router/import.ts",
"apps/server/src/routes/rpc/handlers/health/**",
"apps/server/src/routes/rpc/handlers/status-report/**",
"apps/server/src/routes/rpc/handlers/maintenance/**",
"apps/server/src/routes/rpc/handlers/notification/**",
"apps/server/src/routes/slack/interactions.ts"
],
"ignore": [
// Tests legitimately manage db state for fixtures and cleanup.
"**/__tests__/**",
"**/*.test.ts",
// Notification handler siblings that still read db directly —
// `limits.ts` queries workspace quotas, `converters.ts` needs
// db enum shapes for proto round-trip. Both stay exempt until
// those responsibilities move into services. Using `**` above
// + these ignores (instead of whitelisting just `index.ts`)
// means new files added to the notification handler are
// enforced by default rather than silently slipping through.
"apps/server/src/routes/rpc/handlers/notification/limits.ts",
"apps/server/src/routes/rpc/handlers/notification/converters.ts"
],
"linter": {
"rules": {
"nursery": {
"noRestrictedImports": {
"level": "error",
"options": {
"paths": {
"@openstatus/db": "Use @openstatus/services instead (domain has migrated to the service layer).",
"@openstatus/db/src/schema": "Use @openstatus/services instead.",
"@openstatus/db/src/schema/plan/utils": "Use @openstatus/services instead.",
"@openstatus/db/src/schema/plan/schema": "Use @openstatus/services instead.",
"@openstatus/db/src/schema/plan/config": "Use @openstatus/services instead.",
"drizzle-orm": "Use @openstatus/services instead."
}
}
}
}
}
}
}
]
}