aloisdeniel / aloisdeniel/flutter_sheet_localization
Dynamic key access to translations
- Lingua principale
- Dart
- Stelle
- 286
- Fork
- 87
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Hi,
There are some use-cases (e.g. translations for enum types) where I need to access a dynamic key in runtime. I wonder if this can be achieved with the library without written mapping code in the client? At the moment I am using a workaround where I put the translations as map in a row, and do a runtime check and apply the items, e.g.
key: | en
enum.fruits | {"apple": "Apple", "banana": "Banana", "default": ""...}
But it is not very scalable compared to define "apple", "banana" as separate rows.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.