Open
Description
I found myself want to validate the object
items included into an Array
. However, I didn't find a quick way to do it while working on #281 so I wrote a TODO comment there.
A small example of what I want is on the versions.active
field:
versions: {
type: "object",
required: ["current", "active"],
properties: {
active: {
type: "array",
// TODO: validate each item of the array has the following structure
//
// items: { type: "object" },
// required: ["slug", "urls"],
// properties: {
// slug: { type: "string" },
// urls: {
// type: "object",
// required: ["documentation"],
// properties: {
// documentation: { type: "string" },
// },
// },
// },
},