Sha256: f3a1d3a639ba78e946029f234186ec6301ea2ebc646ba3177f69e12ef767b063

Contents?: true

Size: 320 Bytes

Versions: 5

Compression:

Stored size: 320 Bytes

Contents

# frozen_string_literal: true

module ViewComponent
  module RenderingMonkeyPatch # :nodoc:
    def render(options = {}, args = {})
      if options.respond_to?(:render_in) && Rails.version.to_f < 6.1
        self.response_body = options.render_in(self.view_context)
      else
        super
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
view_component-1.17.0 lib/view_component/rendering_monkey_patch.rb
actionview-component-1.17.0 lib/view_component/rendering_monkey_patch.rb
view_component-1.16.0 lib/view_component/rendering_monkey_patch.rb
actionview-component-1.16.0 lib/view_component/rendering_monkey_patch.rb
actionview-component-1.15.0 lib/view_component/rendering_monkey_patch.rb