Replies: 1 comment 8 replies
-
|
Hello @bwgjoseph , Short answer :Low priority for me atm. Why the low priority ?
Long answer :Open closed principle should be applied here.
For point n°1You can use the import Schema from "@site/static/schemas/examples/refs/refOnRoot.json";
import JSONSchemaViewer from "@theme/JSONSchemaViewer";
const resolverOptions = {"jsonPointer": "#/definitions/user"}
<JSONSchemaViewer schema={ Schema } resolverOptions={resolverOptions} />My example in documentation is a good illustration it already works. For point n°2In my own codebase, bunch of // @ts-ignore
as boolean | number | undefinedto just cover that version. It seems to be an overhead just to support a single version ... For point n°3The hardest as many question aroses :
So I will convert that issue into a discussion to see if other have this need that might help me reconsider my position. PS : 1.2.0 is out. enhancements should be quite visible : feel free to share your feedback ;) |
Beta Was this translation helpful? Give feedback.

Uh oh!
There was an error while loading. Please reload this page.
-
Is it possible to support it?
See mongodb-jsonschema
A sample
{ $jsonSchema: <JSON Schema object> }{ $jsonSchema: { required: [ "name", "major", "gpa", "address" ], properties: { name: { bsonType: "string", description: "must be a string and is required" }, address: { bsonType: "object", required: [ "zipcode" ], properties: { "street": { bsonType: "string" }, "zipcode": { bsonType: "string" } } } } } }If it does, I imagine I would use the same way I did before to display it
Thanks
Beta Was this translation helpful? Give feedback.
All reactions