We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The json-schema specifictaion allows the use of an external definitions file: https://json-schema.org/understanding-json-schema/structuring.html#id1. This avoids repeating types in all files. Is it possible with graphql-mesh's json-schema handler ?
Example:
{ "$ref": "definitions.json#/address" }
Where definitions.json is a file in the same directory and contains an address type:
{ "$schema": "http://json-schema.org/draft-04/schema#", "address": { "type": "object", "properties": { "street_address": { "type": "string" }, "city": { "type": "string" }, "state": { "type": "string" } }, "required": [ "street_address", "city", "state" ] } }
The text was updated successfully, but these errors were encountered:
It is not possible now, and PRs are welcome!
Sorry, something went wrong.
Available in 0.2.1!
Is external ref available for yaml spec? I am getting an error saying:
💥 🕸️ Mesh - Alerts Failed to generate the schema Error: Invalid JSON pointer: ./common.yaml/components/schemas/PageInfo at Function.parse (C:\Repos\graphql-mesh-demo\node_modules\json-pointer\index.js:219:44) at Function.get (C:\Repos\graphql-mesh-demo\node_modules\json-pointer\index.js:49:60)
Yes it works but you should use json pointer syntax.
No branches or pull requests
The json-schema specifictaion allows the use of an external definitions file: https://json-schema.org/understanding-json-schema/structuring.html#id1. This avoids repeating types in all files. Is it possible with graphql-mesh's json-schema handler ?
Example:
Where definitions.json is a file in the same directory and contains an address type:
The text was updated successfully, but these errors were encountered: