You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #247 adopts a typed `V0Error` class for every throw in `packages/0/src` so consumers can identify v0 errors via a stable `code` discriminant. Coverage is currently 8/8 throw sites, but the convention is enforced by author discipline only — nothing stops a future PR from landing a bare `throw new Error(...)`.
Ask
Add a lint rule to `eslint-plugin-vuetify` (or a project-local rule under `packages/0/.eslintrc`) that flags bare `throw new Error(...)` inside `packages/0/src/**/*.ts` and suggests `throw new V0Error(...)` with a code from the `V0ErrorDetails` union.
Suggested semantics
Target: `packages/0/src/**/.ts` excluding `.test.ts` and `*.bench.ts`.
This is the enforcement gap flagged by the type-design review on refactor: attach structured cause to v0 throws #247 ("structural cause shape cannot be safely tested without inspecting `code` — that's the brand").
Without the rule, the registry decays — future authors won't know it exists or will skip it for a bare `Error` when they're in a hurry.
Context
PR #247 adopts a typed `V0Error` class for every throw in `packages/0/src` so consumers can identify v0 errors via a stable `code` discriminant. Coverage is currently 8/8 throw sites, but the convention is enforced by author discipline only — nothing stops a future PR from landing a bare `throw new Error(...)`.
Ask
Add a lint rule to `eslint-plugin-vuetify` (or a project-local rule under `packages/0/.eslintrc`) that flags bare `throw new Error(...)` inside `packages/0/src/**/*.ts` and suggests `throw new V0Error(...)` with a code from the `V0ErrorDetails` union.
Suggested semantics
Notes