-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
It is really great if string with jsodoc generate correct validation for JS/TS
currently:
const code = `
/**
* @format email
*/
type V = string;
`
const model = Codegen.TypeScriptToModel.Generate(code);
console.log(Codegen.ModelToTypeScript.Generate(model));
Result:
export type V = string
export const V = (() => {
function check_V(value: any): boolean {
return typeof value === 'string' && format('email', value)
}
return function check(value: any): value is V {
return check_V(value)
}
})()
I cannot find the implementation of format
Metadata
Metadata
Assignees
Labels
No labels