Skip to content

Commit

Permalink
Fix empty children rendering bug in Rails 7.1. Because our children e…
Browse files Browse the repository at this point in the history
…xplicitly concat on @output_buffer, we should not return anything from capture block. This used to work anyway on Rails <7.1 but it no longer works
  • Loading branch information
patbenatar committed Oct 18, 2023
1 parent 5b37403 commit ce59e0c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/rbexy/configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def transforms

def component_rendering_templates
@component_rendering_templates ||= {
children: "{capture{%{children}}}",
children: "{capture{%{children};nil}}",
component: "::%{component_class}.new(%{view_context},%{kwargs}).render_in%{children_block}"
}
end
Expand Down

0 comments on commit ce59e0c

Please sign in to comment.