i18n-tasks
i18n-tasks copied to clipboard
"normalize" destroys stuff like &defaults
I often use stuff like the following:
de:
activerecord:
attributes:
defaults: &defaults
created_at: 'Erstellt am'
updated_at: 'Aktualisiert am'
user:
<<: *defaults
current_password: Aktuelles Passwort
Sadly, when doing i18n-tasks normalize
, these are "flattened". Is there any way to circumvent this?
Perhaps there is a YAML parser mode that can round-trip this, but I am not aware of one. Related discussion on StackOverflow.
something similar happens here:
insulin_dose:
dose: &dosis Dosis
bolus: Snelwerkend
application_time: &toegediend Toegediend
becomes:
insulin_dose:
application_time: Toegediend
bolus: Snelwerkend
dose: Dosis
so references got lost.
@bertBruynooghe Yes, it's the same thing, the YAML parser can't round-trip this. But in your case you should just use reference keys instead, e.g.:
en:
some_other_key: :insulin_dose.dose