Lots of extracting to t(…) and l(…)
rails-i18n gem helps a lot for supported languages.
Coverage of dates, times, numbers, error messages.
4. Single or Separate DBs?
Each site to have separate products and suppliers
Scoping everything by site - massive amount of work.
Site was MySQL so couldn’t use Postgres schemas for multi-
tenancy (Apartment gem).
Went with separate DBs for UK and German sites.
Schema migrations run on both sites to keep schemas the same.
But used primary key offsets so that we could potentially merge
back together in future.
Changing timezone -> broken tests -> usually due to a badly
Zonebie gem (time zone randomization)
Time.parse -> Time.zone.parse
Time.now -> Time.zone.now
.to_time -> .to_time_in_current_zone
Use ISO8601 for APIs (“2012-03-16T14:55:33Z")
11. Lessons Learned
Stick to Rails conventions
Demo to native speakers as early as you can
Consider i18n-friendly-by-default approach:
Store all strings in YAML conﬁg
Wrap date/number/currency calls in l(…) in views