Skip to content

Instantly share code, notes, and snippets.

@geraintluff
Last active December 11, 2015 23:38
Show Gist options
  • Save geraintluff/4678054 to your computer and use it in GitHub Desktop.
Save geraintluff/4678054 to your computer and use it in GitHub Desktop.
{
"main": "food",
"sub": "bread"
}
{
"type": "object",
"required": ["main", "sub"],
"oneOf": [
{
"title": "Food menu",
"properties": {
"main": {"enum": ["food"]},
"sub": {"enum": ["bread","steak"]}
}
},
{
"title": "Drink menu",
"properties": {
"main": {"enum": ["drinks"]},
"sub": {"enum": ["water","juice"]}
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment