Start I18n Internationalization setup #276
Reference in New Issue
Block a user
Delete Branch "feat/internationalization_setup"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Start Internationalization Setup
Close #256
TODOS:
tiny detail but some files are
.ymlsome are.yaml@@ -4,4 +3,1 @@def type_name"Credit Card"endendCan use:
credit.model_name.humanisn't used in any action
@Shpigford i thinks the initial setup is done.
@ricsdeol Please resolve conflicts + failing tests.
@Shpigford I fixed the missing keys, however the unused test is we can't use, it doesn't recognize when using some translations dynamically like here:
or
or others 'rails default' like here:
which is a good practice to facilitate translation into other languages or add date custom formats.
I suggest disabling this test for now, then we can enable and check how to configure these cases.
Do the suggestions in https://github.com/glebm/i18n-tasks#dynamic-keys help with this?
Doesn't work with active record attributes and name like this:
I think we should ignore those in the config instead of skipping the test. If we skip, enabling down the road will be a pain as we'll be missing context for which keys can safely be ignored.
For that same reason, I'd suggest adding a note to the config about why we're ignoring these in particular and how we are, in fact, using them (i.e. via model_name.human).
I see we use the model names in template. So fine to ignore those. Do we use the attribute names as well? (E.g in validations) If not, I'd avoid adding them now. I18n files can get unruly, so would rather only add what we absolutely need.
Thanks @josefarias I did your suggestion.
@Shpigford Please could re-evaluate these changes?
There's an error but I'm ignoring. Going to merge and then just kill of the system tests as they're getting in the way of our quickly-changing UI.
Thanks for tackling this, @ricsdeol!