Sha256: 5bd64b720252e4bd694b8d30806bf0f068ce0c94c859dbea0398d7e0e9966be4
Contents?: true
Size: 443 Bytes
Versions: 3
Compression:
Stored size: 443 Bytes
Contents
require 'blueprint/blueprint' require 'blueprint/components' require 'blueprint/utils' def blueprint(*args, &block) blueprint_def = args.last.is_a?(Hash) ? args.pop : {} if blueprint_def.empty? blueprint_def[:label] = args.pop end if blueprint_def[:type] blueprint_def[:item_type] = blueprint_def.delete(:type) end blueprint = Blueprint.new(blueprint_def) if block_given? yield blueprint end blueprint end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
webbynode-blueprint-0.0.3 | lib/blueprint.rb |
webbynode-blueprint-0.0.4 | lib/blueprint.rb |
webbynode-blueprint-0.0.5 | lib/blueprint.rb |