Sha256: 89cd760e759bad855473f14a1b2f79d125d090b3d90ae1c279703a5bc8014682

Contents?: true

Size: 380 Bytes

Versions: 1

Compression:

Stored size: 380 Bytes

Contents

require_relative "../../lib/theme_partials"

module ThemeHelper
  include ThemePartials

  def current_theme
    THEME_DIRECTORY_ORDER.first
  end

  def render(options = {}, locals = {}, &block)
    if options.is_a?(String)
      theme_partial = Resolver.resolve(options)

      return super theme_partial, locals, &block unless theme_partial.blank?
    end

    super
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bullet_train-themes-1.0.1 app/helpers/theme_helper.rb