fix(core-consent): build consent router from the shared superjson t

The router previously created its own initTRPC without superjson while
the app router uses the shared transformer-enabled instance — a wire
transformer mismatch that corrupts inputs (audit finding A10). Procedures
now build on @repo/core-shared/trpc/init's t; a real client+fetch-adapter
round-trip test pins Date revival through appRouter-style mounting.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-10 17:46:46 +02:00
parent e2a4657471
commit 8b78563881
4 changed files with 112 additions and 11 deletions

View File

@@ -36,8 +36,10 @@
"@repo/core-testing": "workspace:*",
"@repo/core-typescript": "workspace:*",
"@testing-library/react": "^16.0.0",
"@trpc/client": "^11.18.0",
"@types/react": "^19.0.0",
"@vitest/coverage-v8": "^3.2.7",
"superjson": "^2.2.1",
"jsdom": "^25.0.0",
"payload": "^3.14.0",
"react": "^19.0.0",