Sha256: ea7df9ad39eda03fd64ca67a8824d94c73b50ac10bc00a4619d44eee1c4b9145
Contents?: true
Size: 560 Bytes
Versions: 15
Compression:
Stored size: 560 Bytes
Contents
require 'i18n' require 'active_support/core_ext/array/extract_options' module Spree class TranslationHelperWrapper # :nodoc: include ActionView::Helpers::TranslationHelper end class << self # Add spree namespace and delegate to Rails TranslationHelper for some nice # extra functionality. e.g return reasonable strings for missing translations def translate(key, options={}) options[:scope] = [:spree, *options[:scope]] TranslationHelperWrapper.new.translate(key, options) end alias_method :t, :translate end end
Version data entries
15 entries across 15 versions & 1 rubygems