We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent da65f31 commit e69df49Copy full SHA for e69df49
README.md
@@ -105,17 +105,16 @@ const person = object({
105
age: number(),
106
})
107
108
-const team = object(
109
- {
110
- leader: $ref('person'),
111
- members: array($ref('person')),
112
- },
113
114
- $defs: { person },
115
116
-)
+const team = object({
+ leader: $ref('person'),
+ members: array($ref('person')),
+})
+
+team.$defs = { person }
117
```
118
+> Read more about `$ref` and `$defs` in the [JSON Schema Documentation](https://json-schema.org/understanding-json-schema/structuring#dollarref)
119
## 🔀 Using Union Types
120
121
Create union types using `anyOf` to allow multiple possible schemas:
0 commit comments