# Report a bug ### π Search Terms <!-- What search terms did you use when trying to find an existing bug report? List them here so people in the future can find this one more easily. --> ### π§© Context - ArkType version: 2.2.0 - TypeScript version (5.1+): 6.0-beta - Other context you think may be relevant (JS flavor, OS, etc.): Bun + node <!-- For an easy way to generate this information, run `npx envinfo --system --binaries --npmPackages "{arktype,@ark/*,typescript}" --fullTree` --> ### π§βπ» Repro <!-- 1. Update the playground link below with the simplest code you can that reproduces the issue. 2. Click the link icon in the top right corner of the playground editor to copy the URL for your repro. 3. Replace the URL below with your repro link. If your repro requires dependencies besides arktype, it's probably either not a minimal repro or not an arktype bug. You can still describe it here, but is likely to be closed. --> Playground Link: https://arktype.io/playground?code=import%2520%257B%2520type%2520%257D%2520from%2520%2522arktype%2522%250A%250Aconst%2520Thing%2520%253D%2520type%28%257B%2520a%253A%2520%2522string%2522%2520%257D%29.or%28%2522null%2522%29%250A%250Aconsole.log%28Thing.toJsonSchema%28%257B%2520useRefs%253A%2520true%2520%257D%29%29%250A%250Aconst%2520out%2520%253D%2520Thing%28%257B%250A%2509a%253A%2520%2522string%2522%250A%257D%29%250A ```ts const Thing = type({ a: "string" }).or("null") console.log(Thing.toJsonSchema({ useRefs: true })) ``` Note: in my code, useRefs is being set to true due to cyclic types, but this is the minimal repro.
Report a bug
π Search Terms
π§© Context
π§βπ» Repro
Playground Link: https://arktype.io/playground?code=import%2520%257B%2520type%2520%257D%2520from%2520%2522arktype%2522%250A%250Aconst%2520Thing%2520%253D%2520type%28%257B%2520a%253A%2520%2522string%2522%2520%257D%29.or%28%2522null%2522%29%250A%250Aconsole.log%28Thing.toJsonSchema%28%257B%2520useRefs%253A%2520true%2520%257D%29%29%250A%250Aconst%2520out%2520%253D%2520Thing%28%257B%250A%2509a%253A%2520%2522string%2522%250A%257D%29%250A
Note: in my code, useRefs is being set to true due to cyclic types, but this is the minimal repro.