arktype
arktype copied to clipboard
Declared scopes
Would add support for declaring the inferred types of an entire scope, with autocomplete for alias names.
Similar to existing API for declared types (in beta).
Maybe something like:
declare<{
a: string;
b: {
key: "value";
};
}>().scope({
a: "string",
b: {
key: "'value'",
},
});
Thanks @Dimava for the API suggestion!
key: "'value'";
just key: 'value';
@Dimava Good catch, to used to writing AT definitions 😅 Will fix!