Sha256: a895e9a84354982140b34b15631c5405ae75532d07ec8f421da1d51bf41ab522

Contents?: true

Size: 534 Bytes

Versions: 5

Compression:

Stored size: 534 Bytes

Contents

# frozen_string_literal: true

require "pakyow/support/extension"

module Pakyow
  module Presenter
    class Renderer
      module Behavior
        # @api private
        module CleanupPrototypeNodes
          extend Support::Extension

          apply_extension do
            build do |view|
              unless Pakyow.env?(:prototype)
                view.object.each_significant_node(:prototype, descend: true).map(&:itself).each(&:remove)
              end
            end
          end
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
pakyow-presenter-1.0.6 lib/pakyow/presenter/renderer/behavior/cleanup_prototype_nodes.rb
pakyow-presenter-1.0.5 lib/pakyow/presenter/renderer/behavior/cleanup_prototype_nodes.rb
pakyow-presenter-1.0.4 lib/pakyow/presenter/renderer/behavior/cleanup_prototype_nodes.rb
pakyow-presenter-1.0.3 lib/pakyow/presenter/renderer/behavior/cleanup_prototype_nodes.rb
pakyow-presenter-1.0.2 lib/pakyow/presenter/renderer/behavior/cleanup_prototype_nodes.rb