how to build tRPC and Prisma with express?
How to infer types from input?
How to infer types of a query
const hello = trpc.hello.useQuery();
I would like to export the type we get on hover(on hello).
...Data Visualisation/Charts
trpc + AWS Lambda (through cdk)
Is it possible to narrow an output schema if the query optionally doesn't return all fields?
filter
that changes the shape of the data to only include those fields (like sql select
), but those records will fail the output schema which contains all of the fields as required. is there a way to construct a .output()
specification that narrows the type, possibly using z.partial() so that these partial "rows" will pass output validation?Fetching different server url than defined in config
/address-middleware
instead of hitting /trpc/....
Can I do that? I dont want to setup separate reactquery provider or something just to call one separate endpointError types in catch block
input using z.or not working properly
How can I disable batching with fastify adapter?
Issue with monorepo architecture ant tRPC
Cannot read properties of undefined (reading 'messsage')
so I have read that at least error problem was fixed in newer versions, so we tried to update version, but then the builds started to fail. We get this error (photos in the thread) and more information
Using tRPC in CRON jobs
async createContext for Express Adapter
Is it possible to split the router definition with the imlementation?
Cache not working for `useQuery`
Zod File Upload Validation with Open-Api Support?
Zod validation and open-api support for File on the server?
is context cached?
JSON inferred router output not matching
JsonValue
(definitions below).
The inferred type from the router.procedure.query()
on a createTRPCProxyClient
instance comes back as expected, but the type definition using inferRouterOutputs<AppRouter>
types the Json data as string | null
.
Any ideas? Thanks. New to tRPC so sorry if this is a no-brainer....Best way to implement input based validation on a router procedure