Bert
Bert
Explore posts from servers
Aarktype
Created by Bert on 11/29/2024 in #questions
Test that a string contains a substring?
Test that a string contains a substring?
9 replies
Aarktype
Created by Bert on 8/21/2024 in #questions
String length
equivalent to z.string().min(1)?
10 replies
TtRPC
Created by Bert on 11/25/2023 in #❓-help
tRPC is butchering object types in return types
So if I have a mutation that returns this type
{ name?: string }
{ name?: string }
the type that tRPC infers for the mutation is
type R = ReturnType<typeof trpcClient.mut.mutate>
R = Promise<Record<"name", string | undefined>>
type R = ReturnType<typeof trpcClient.mut.mutate>
R = Promise<Record<"name", string | undefined>>
This is not the same, with exactOptionalPropertyTypes. Anyone familiar with this who can provide some info about it?
6 replies