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
First, I'd like to thank you for your amazing plugin which we are now using in our production app. I found the "official" way with ARBs and this ton of autogenerated files too clumsy, while the JSON + this plugin makes our life a breeze.
My only concern was that currently it's kind of encapsulated only as a VS Code plugin, so there is no way to use it in other editors + as part of any script too.
Are you open for discussion of extracting the main logic to an npm package "as-is" and making the VSCode plugin just call these functions?
Thank you very much!
The text was updated successfully, but these errors were encountered:
I practically was able to build a test "CLI" version of the generator very easily by just replacing all the ua.prompt calls to explicit function parameters. And it worked out of the box (npm run compile, npm run try-it in my fork), I tested it on our localizations json files and it converted them successfully.
I of course know that this is a very hacky solution right now, but I was just playing with it to understand the complexity of the task and how hard it potentially might be to do so. Looks like the code is pretty easily decoupled.
If it helps, I wrote an alternative dart code generator in dart. it takes the json files that were created with this vs code plugin and generate the dart code. https://github.com/gnudles/dart_i18n_generator
add it to dev dependencies in pubspec.yaml and generate i18n.dart by running the command
flutter pub run i18n_json:i18n_json
I would be glad if others would try it and contribute to it, to make a pure dart cli interface
Hello @esskar ,
First, I'd like to thank you for your amazing plugin which we are now using in our production app. I found the "official" way with ARBs and this ton of autogenerated files too clumsy, while the JSON + this plugin makes our life a breeze.
My only concern was that currently it's kind of encapsulated only as a VS Code plugin, so there is no way to use it in other editors + as part of any script too.
Are you open for discussion of extracting the main logic to an npm package "as-is" and making the VSCode plugin just call these functions?
Thank you very much!
The text was updated successfully, but these errors were encountered: