Skip to content

Commit

Permalink
Fix out of order rendering when yielding from a partial rendered with…
Browse files Browse the repository at this point in the history
… a block delegated from a component’s content block
  • Loading branch information
joeldrapper committed Oct 18, 2023
1 parent 415c4be commit b0cc8bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/phlex/rails/sgml/overrides.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def render(*args, **kwargs, &block)
when Enumerable
return super unless renderable.is_a?(ActiveRecord::Relation)
else
@_context.target << @_view_context.render(*args, **kwargs, &block)
@_context.target << @_view_context.render(*args, **kwargs) { capture(&block) }
end

nil
Expand Down

0 comments on commit b0cc8bc

Please sign in to comment.