work-hub-server/openspec/changes/archive/2026-06-04-swap-superstruct-valibot/tasks.md
Nicolas HOARAU 9190908062 docs: archive completed changes
Archive add-shared-schema-package and swap-superstruct-valibot changes to openspec/changes/archive/
2026-06-04 12:49:12 +04:00

26 lines
1 KiB
Markdown

## 1. Dependency swap
- [x] 1.1 Remove `superstruct` from `packages/schema/package.json` dependencies
- [x] 1.2 Add `valibot` to `packages/schema/package.json` dependencies
## 2. Create Valibot schemas
- [x] 2.1 Create `packages/schema/src/valibot.ts` with `createInsertSchema` and `createUpdateSchema` for `projects` and `tasks`
- [x] 2.2 Add `picklist()` refinements for enum fields (`status`, `priority`) using the constant arrays from `drizzle/enums.ts`
- [x] 2.3 Export insert and update schemas as named exports
## 3. Remove old modules
- [x] 3.1 Delete `packages/schema/src/validation/` directory
- [x] 3.2 Delete `packages/schema/src/types/` directory
## 4. Update barrel export
- [x] 4.1 Update `packages/schema/src/index.ts` to export Drizzle tables and Valibot schemas (remove old validation/types exports)
## 5. Verify
- [x] 5.1 Run `pnpm --filter=@workspace/schema build` to confirm compilation
- [x] 5.2 Run `pnpm build` from root to confirm full monorepo integrity
- [x] 5.3 Run `pnpm --filter=api test` to confirm no regressions