Sha256: bf41da86ef0bde3c6cfade55802952c191a7aa27024712c292a85e8794eb6581

Contents?: true

Size: 700 Bytes

Versions: 5

Compression:

Stored size: 700 Bytes

Contents

# frozen_string_literal: true

require "pakyow/support/extension"

module Pakyow
  module Presenter
    module Behavior
      module Exposures
        extend Support::Extension

        apply_extension do
          unless ancestors.include?(Plugin)
            # Copy exposures from the plugin renderer.
            #
            after "load.plugins" do
              plugs.each do |plug|
                plug.isolated(:Renderer).__expose_fns.each do |fn|
                  isolated(:Renderer).send(:expose) do |connection|
                    fn.call(connection, plug)
                  end
                end
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
pakyow-presenter-1.0.0.rc5 lib/pakyow/presenter/behavior/exposures.rb
pakyow-presenter-1.0.0.rc4 lib/pakyow/presenter/behavior/exposures.rb
pakyow-presenter-1.0.0.rc3 lib/pakyow/presenter/behavior/exposures.rb
pakyow-presenter-1.0.0.rc2 lib/pakyow/presenter/behavior/exposures.rb
pakyow-presenter-1.0.0.rc1 lib/pakyow/presenter/behavior/exposures.rb