const A = z.string(); type A = z.infer<typeof A>; // string const u: A = 12; // TypeError const u: A = "asdf"; // compiles