Sha256: 84cfd48bc81fbc56fe3f2a32909e9f1b83160ea518b185abe5d53b218ef75269

Contents?: true

Size: 301 Bytes

Versions: 3

Compression:

Stored size: 301 Bytes

Contents

require "menuizer/version"
require "menuizer/menu"

module Menuizer
  class << self
    def configure(namespace=nil)
      yield (map[namespace] = Menu.new(namespace))
    end
    def menu(namespace=nil)
      map[namespace]
    end

    private

      def map
        @map ||= {}
      end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
menuizer-0.1.5 lib/menuizer.rb
menuizer-0.1.2 lib/menuizer.rb
menuizer-0.1.1 lib/menuizer.rb