ofcyln / i18n-json-to-xlsx-converter

i18n JSON to XLSX Converter is a CLI tool runs in a terminal, and helps you to convert a JSON file(s) to EXCEL sheet(s) including keys column defined as nested with dot notation, and the values column for those keys. Also, the CLI tool converts an EXCEL sheet to JSON file(s) by considering its values columns as individual files.
https://www.npmjs.com/package/i18n-json-to-xlsx-converter
MIT License
46 stars 13 forks source link

Empty cells rule #1

Open picks44 opened 2 years ago

picks44 commented 2 years ago

Hello,

Thanks a million for this wonderful tool. I've been looking for this for years, and it is so time-saving...

Just one enhancement that would be appreciated: if we add a new translation key in the Excel file, then all columns (except English for instance) are empty (until they get translated by agencies). When converting to JSON, then the key value is set to null. This strategy is preventing our app fallback strategy from working, meaning that if I switch my app to FR for instance, then the value displayed is also "null".

Could you add an option to the command in order to remove the key woth empty values from the JSON? This would allow the fallback strategy to work properly. Make it an option in case other projects needs to have the null value :)

What do you think?

ofcyln commented 2 years ago

Hello,

I'm glad this tool made you save time. Your suggestion is accurate, instead of unsemantic null words for untranslated or new fields, there could be an option to bypass those labels or even keep them as empty fields (as long as JS let us do that). I'll work on this improvement.