Sha256: 669bc64e9220b5d955b311275d5c6f59ca43c051b7f56a050f8a27e25bf27059
Contents?: true
Size: 532 Bytes
Versions: 1
Compression:
Stored size: 532 Bytes
Contents
module Trailblazer::V2_1::Rails::Controller::Cell private # rubocop:disable Lint/UselessAccessModifier module Render def render(cell = nil, options = {}, *, &block) return super unless cell.kind_of?(::Cell::ViewModel) render_cell(cell, options) end def render_cell(cell, options) options = options.reverse_merge(layout: true) # render the cell. content = cell.() render({html: content}.merge(options)) end end include Render unless method_defined?(:render_cell) end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
trailblazer-future-2.1.0.rc1 | lib/trailblazer/v2_1/rails/cell.rb |