Reputation: 419
In YAML, for I18n Rails translations, I have
en:
mainkey:
subkey: 'Some Text'
I can retrieve en.mainkey.subkey, but how can I assign a text to en.mainkey !?
Upvotes: 1
Views: 1348
Reputation: 4492
You can't. The value of en.mainkey
is the hash containing subkey
. It can't also be a string. You can e.g. put it under another key next to subkey.
Upvotes: 1