Resolving type and its nodes
I'm making a simple arktype to openapi transformer. What's the best way to get type's definition to use in logic? I mean literally like type('string')._def.type === 'string' etc.
2 Replies
ArkType Docs
TypeScript's 1:1 validator, optimized from editor to runtime

type.json
is arguably better here since that's the actual internal ArkType schema
type.expression
is just a human readable version of it, but isn't as good for introspectability