arktype
arktype copied to clipboard
Type is not assignable to type when using `.or()` on a `type()` passed as parameter of `type().and()`
Report a bug
🔎 Search Terms
Typescript 5.5
🧩 Context
- ArkType version: 2.0.0-dev.11
- TypeScript version: 5.4.5, 5.5.0-beta
- Other context you think may be relevant (Node version, OS, etc.): Node v22
🧑💻 Repro
import { type } from "arktype"
const badType = type({
someField: "string"
})
.and(
type({
action: "'a' | 'b'"
})
.or({
action: "'c'"
})
);