Skip to content

Instantly share code, notes, and snippets.

@TheFoot
Last active September 4, 2015 07:57
Show Gist options
  • Save TheFoot/e69bc79610d2e26729b5 to your computer and use it in GitHub Desktop.
Save TheFoot/e69bc79610d2e26729b5 to your computer and use it in GitHub Desktop.
Proposed structure for a logic condition object. Organising languages by using a keyed collection is easier to traverse and use than an indexed array of objects.
{
"EN": {
"text": "Barrier breached",
"items": [
{
"value": "yes",
"text": "Yes"
},
{
"value": "no",
"text": "No"
}
]
},
"FR": {
"text": "Barrière touchée",
"items": [
{
"value": "yes",
"text": "Oui"
},
{
"value": "no",
"text": "Non"
}
]
},
"DE": {
"text": "Barriere berührt",
"items": [
{
"value": "yes",
"text": "Ja"
},
{
"value": "no",
"text": "Nein"
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment