Skip to content

Instantly share code, notes, and snippets.

@jhawthorn
Created January 26, 2018 23:27
Show Gist options
  • Save jhawthorn/088cba703950f57d719c46cce422d5c5 to your computer and use it in GitHub Desktop.
Save jhawthorn/088cba703950f57d719c46cce422d5c5 to your computer and use it in GitHub Desktop.
class I18nLogger
include I18n::Backend::Base
include I18n::Backend::Flatten
def available_locales
['en']
end
def lookup(locale, key, scope = [], options = {})
p [locale, key, {scope: scope, options: options}]
nil
end
end
I18n.backend = I18n::Backend::Chain.new(I18nLogger.new, I18n.backend)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment