'yes' and 'no' keys in Rails translations yaml
yes
and no
represent true
and false
in Yaml (see the yaml spec). The Ruby yaml parser has tests to make sure yes
and no
get evaluated as booleans.
That means you need to put these keys in quotes in translation files:
en:
'yes': Yes
'no': No
Without the quotes you get a missing translation error when trying to access them with I18n.t('yes')
or I18n.t('no')