-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
enhancementNew feature or requestNew feature or request
Milestone
Description
A way to deal with string arrays would be useful.
For example say I want strings for days of the week...
The json might look like...
{
"days_of_week": [
{"monday": "Monday"},
{"tuesday": "Tuesday"},
{"wednesday": "Wednesday"},
{"thursday": "Thursday"},
{"friday": "Friday"},
{"saturday": "Saturday"},
{"sunday": "Sunday"},
]
}
In code the strings would be accessed as...
Translation.of(context).daysOfWeek[index];
What would be even better would be to support aliases. This would allow the members of the array to reference string literals already defined.,
{
"monday": "Monday",
"tuesday": "Tuesday",
"wednesday": "Wednesday",
"thursday": "Thursday",
"friday": "Friday",
"saturday": "Saturday",
"sunday": "Sunday",
"days_of_week": [
{"monday": "@string/monday"},
{"tuesday": "@string/tuesday"},
{"wednesday": "@string/wednesday"},
{"thursday": "@string/thursday"},
{"friday": "@string/friday"},
{"saturday": "@string/saturday"},
{"sunday": "@string/sunday"},
]
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request