You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be great to add a localization generator from json files to get_cli, while generating an abstract class with keys and translation maps, just like in the easy_localization package.
Activity
alexkharech commentedon Sep 3, 2020
can be a simple key / value map
roipeker commentedon Sep 3, 2020
Agree 💯 , super useful feature for code generation.
alexkharech commentedon Sep 3, 2020
I have implemented this, now I will post a pull request
CpdnCristiano commentedon Sep 3, 2020
What a fantastic idea, I really liked it
alexkharech commentedon Sep 3, 2020
PR #7
assets/locales - input directory with json files
output file
lib/generated/locales.g.dartCpdnCristiano commentedon Sep 3, 2020
congratulations!! you did an excellent job
CpdnCristiano commentedon Sep 3, 2020
I will close this issue
jnickzlim commentedon Jan 10, 2021
Sorry for the dump question, but i could not figure out how to use the generated locales.
main.dart
i have tried:
Thank you for the help in advance.
CpdnCristiano commentedon Jan 10, 2021
is the text output in English or it's empty?
jnickzlim commentedon Jan 10, 2021
The out put is titles_home instead of it's content.
jnickzlim commentedon Jan 11, 2021
@CpdnCristiano or any one please help?
The generated locales.g.dart:
In the app it shows the
titles_homeinstead ofHomeor首页CpdnCristiano commentedon Jan 11, 2021
you generated for the locale
en_ENand are sitting on the appen_USjnickzlim commentedon Jan 11, 2021
Thank you for the shape eye, didn't notice the example was using
ENinstead ofUSCheers~!