Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/model/model-to-valibot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export namespace ModelToValibot {
return Type(`v.never`, null, [])
}
function Null(schema: Types.TNull) {
return Type(`v.null_`, null, [])
return Type(`v.null`, null, [])
}
function String(schema: Types.TString) {
const constraints: string[] = []
Expand Down Expand Up @@ -153,7 +153,7 @@ export namespace ModelToValibot {
return UnsupportedType(schema)
}
function Undefined(schema: Types.TUndefined) {
return Type(`v.undefined_`, null, [])
return Type(`v.undefined`, null, [])
}
function Union(schema: Types.TUnion) {
const inner = schema.anyOf.map((schema) => Visit(schema)).join(`, `)
Expand All @@ -163,7 +163,7 @@ export namespace ModelToValibot {
return Type(`v.unknown`, null, [])
}
function Void(schema: Types.TVoid) {
return Type(`v.void_`, null, [])
return Type(`v.void`, null, [])
}
function UnsupportedType(schema: Types.TSchema) {
return `v.any(/* unsupported */)`
Expand Down