Sha256: d9dade19687ca9c044a85ad51c3f836c9e66bbae0fef0e05b78dacdb62f58827

Contents?: true

Size: 281 Bytes

Versions: 3

Compression:

Stored size: 281 Bytes

Contents

module Hotcell
  module Commands
    class Scope < Hotcell::Block
      def process context, scope = {}
        context.scoped scope do
          subnodes.first.try(:render, context)
        end
      end
    end
  end
end

Hotcell.register_command scope: Hotcell::Commands::Scope

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
hotcell-0.3.0 lib/hotcell/commands/scope.rb
hotcell-0.2.0 lib/hotcell/commands/scope.rb
hotcell-0.1.0 lib/hotcell/commands/scope.rb