Class: RailsBand::ActionView::Event::RenderTemplate
- Includes:
- FromViews
- Defined in:
- lib/rails_band/action_view/event/render_template.rb
Overview
A wrapper for the event that is passed to render_template.action_view.
Instance Attribute Summary
Attributes inherited from BaseEvent
#allocations, #cpu_time, #duration, #end, #idle_time, #name, #time, #transaction_id
Instance Method Summary collapse
Methods inherited from BaseEvent
Constructor Details
This class inherits a constructor from RailsBand::BaseEvent
Instance Method Details
#identifier ⇒ Object
12 13 14 |
# File 'lib/rails_band/action_view/event/render_template.rb', line 12 def identifier @identifier ||= from_views(@event.payload.fetch(:identifier)) end |
#layout ⇒ Object
16 17 18 19 20 |
# File 'lib/rails_band/action_view/event/render_template.rb', line 16 def layout return @layout if defined? @layout @layout = @event.payload[:layout]&.then { |layout| from_views(layout) } end |