quicktype icon indicating copy to clipboard operation
quicktype copied to clipboard

Error when generating from JSON Schema with overriden allOf property

Open DanielBretzigheimer opened this issue 2 years ago • 0 comments

Hey, I get the error Value of type string is not valid JSON Schema at ... when generating TypeScript from the following JSON Schema.

JSON Schema file

{
	"allOf": [
		{
			"$ref": "https://XXX.de/schemas/order/Test.json#"
		}
	],
	"properties": {
		"msgId": {
			"const": "Test456"
		}
	}
}

/* referenced Test.json */
{
	"type": "object",
	"properties": {
		"msgId": {
			"const": "Test123"
		}
	}
}

I will create a PR which resolves this issue.

DanielBretzigheimer avatar Jul 09 '23 22:07 DanielBretzigheimer