transloco icon indicating copy to clipboard operation
transloco copied to clipboard

Feature(utils): Check unused translation keys

Open pumano opened this issue 2 years ago • 3 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Which Transloco package(s) will this feature affect?

Don't know / other

Is your feature request related to a problem? Please describe

Common not resolved problem in large scale projects is - continuous support of translation keys.

Features changed, but keys rarely deleted from .json files.

Describe the solution you'd like

Would love to see some console command for checking that keys from some language json file is exist inside project.

Just need to check that key is exist inside project and works as expected. And show list of unused translation keys when command finished.

It give possibility to maintain translation keys effectively, and possible to add checks in CI/CD pipeline for better quality.

Describe alternatives you've considered

mostly manually check keys inside IDE and it's not efficient

Additional context

No response

I would like to make a pull request for this feature

No

pumano avatar Aug 04 '22 11:08 pumano

Currently I delete the the entire JSON file and regenerate it. And then take the keys and do a diff with my existing JSON to find missing paramters. Would be great if there is a simple util which can do this for me !

AbdealiLoKo avatar Aug 30 '22 05:08 AbdealiLoKo

Checkout https://github.com/ngneat/transloco-keys-manager -- it does exactly the thing you look for ;)

zstundys avatar Sep 16 '22 15:09 zstundys

@zstundys thank you, I will check it soon

pumano avatar Sep 17 '22 07:09 pumano

@zstundys Thanks for referencing. @pumano Closing this. feel free to interact with the keys-manager repo if needed.

shaharkazaz avatar Dec 16 '22 13:12 shaharkazaz