Search
Star
Feedback
Setup for Free
© 2026 Hedgehog Software, LLC
Twitter
GitHub
Discord
System
Light
Dark
More
Communities
Docs
About
Terms
Privacy
Boolean String (or my first type) - arktype
a
arktype
•
2y ago
•
34 replies
robkuz
Boolean String (or my first type)
How can I create a type that allows for
"boolean like
" inputs and yields a boolean
. As a typesignature I would like to have something like this
(x
: boolean
| 1
| 0
|
"Y
"
|
"N
"
|
"true
"
|
"false
"
)
: boolean
arktype
Join
This is a friendly space centered around ArkType, TypeScript's 1:1 validator (https://github.com/arktypeio/arktype)
860
Members
View on Discord
Resources
ModelContextProtocol
ModelContextProtocol
MCP Server
Recent Announcements
Similar Threads
Was this page helpful?
Yes
No
Similar Threads
Modeling string template type
a
arktype / questions
10mo ago
template literal/backtick string types e.g. type T = `type-${string}`
a
arktype / questions
2y ago
Empty string or number
a
arktype / questions
12mo ago
Accept number in string type
a
arktype / questions
2y ago