Closed lexwebb closed 1 year ago
Hello,
I'm having an issue converting a relatively simple JSON schema using the CLI, however the same schema gets converted correctly on the demo site.
I've condensed the schema down to a minimum failing example, which you can find below:
{ "$schema": "http://json-schema.org/draft-07/schema#", "$ref": "#/definitions/Bestiary", "definitions": { "Bestiary": { "type": "object", "properties": { "name": { "type": "string" } }, "required": ["name"] } } }
This results in an output of export const schema = z.any();
export const schema = z.any();
It's quite possible that i'm missing something, but using simple object based schemas that don't use $ref and definitions seems to work fine on the CLI.
$ref
definitions
Use -d
-d
Hello,
I'm having an issue converting a relatively simple JSON schema using the CLI, however the same schema gets converted correctly on the demo site.
I've condensed the schema down to a minimum failing example, which you can find below:
This results in an output of
export const schema = z.any();
It's quite possible that i'm missing something, but using simple object based schemas that don't use
$ref
anddefinitions
seems to work fine on the CLI.