You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but it seems that json2ts is not able to read the references from the json file, here is one small piece of the json content from that google-endpoint:
{
"$schema": "http://json-schema.org/draft-07/schema#",
"allOf": [
{
"if": {
"properties": {
"@type": {
"const": "MediaService"
}
}
},
"then": {
"$ref": "#/definitions/generics/MediaService"
}
},
... // cut out more entries for the sake of clarity
]
}
and this is basically the output that is generated out of that:
So what I would expect to happen is that json2ts would be able to read from the reference in the json file of "MediaService" which would be in that case this ref "#/definitions/generics/MediaService" which would be at the end this url https://developers.google.com/actions/media/tools/schema_livetv.json#/definitions/generics/MediaService
and then to create the according type definition. I've seen there is a way to set a configuration of $refOptions in the cli commands, but I'm completely clueless how to be able to use this option.
If there is feedback of how I could create the types of this json schema definition in an alternative way - please let me know! :)
The text was updated successfully, but these errors were encountered:
I'm trying to create a static typescipt typings base on this JSON schema from google: https://developers.google.com/actions/media/tools/schema_livetv.json
In order to test things locally I've copy-pasted the content of this endpoint into an output.json (removed the comments in this file)
and ran the following:
but it seems that
json2ts
is not able to read the references from the json file, here is one small piece of the json content from that google-endpoint:and this is basically the output that is generated out of that:
So what I would expect to happen is that
json2ts
would be able to read from the reference in the json file of"MediaService"
which would be in that case this ref"#/definitions/generics/MediaService"
which would be at the end this urlhttps://developers.google.com/actions/media/tools/schema_livetv.json#/definitions/generics/MediaService
and then to create the according type definition. I've seen there is a way to set a configuration of
$refOptions
in the cli commands, but I'm completely clueless how to be able to use this option.If there is feedback of how I could create the types of this json schema definition in an alternative way - please let me know! :)
The text was updated successfully, but these errors were encountered: