Sha256: 6436110975d93d35d4b839e8e92727d8a2e954f7f0137446eff0f66f0bc59b93
Contents?: true
Size: 377 Bytes
Versions: 71
Compression:
Stored size: 377 Bytes
Contents
module Coco module Concerns module Translatable extend ActiveSupport::Concern def tt(key) t("coco.#{self.class.i18n_path}.#{key}") end class_methods do def i18n_path(path = nil) @_i18n_path = path unless path.nil? @_i18n_path ||= component_path.underscore.tr("/", ".") end end end end end
Version data entries
71 entries across 71 versions & 1 rubygems