Sha256: 66c1a6e9fcb6ca741d68f96f8bd0f92ae2fbde6efc769e4c77f3df95f0305ccd

Contents?: true

Size: 739 Bytes

Versions: 11

Compression:

Stored size: 739 Bytes

Contents

require 'active_support'
require "active_support/core_ext/module" # so we can use mattr_accessor
require 'active_record'
require 'ordered_tree'
require 'navi/navigable/base'
require 'navi/railtie' if defined?(Rails) # so we can include the rendering helper into Rails

module Navi
  autoload :Helpers, 'navi/helpers'

  module Navigator
    autoload :Base, 'navi/navigator/base'
  end

  module Renderers
    autoload :Base, 'navi/renderers/base'
    autoload :SimpleNavigation, 'navi/renderers/simple_navigation'
  end

  def self.navigator_class
    self.navigator.to_s.classify.constantize
  end

  mattr_accessor :navigator
  @@navigator ||= :nav_item

  mattr_accessor :renderer
  @@renderer ||= Navi::Renderers::SimpleNavigation
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
navi-0.0.17 lib/navi.rb
navi-0.0.16 lib/navi.rb
navi-0.0.15 lib/navi.rb
navi-0.0.14 lib/navi.rb
navi-0.0.13 lib/navi.rb
navi-0.0.12 lib/navi.rb
navi-0.0.11 lib/navi.rb
navi-0.0.10 lib/navi.rb
navi-0.0.9 lib/navi.rb
navi-0.0.6 lib/navi.rb
navi-0.0.2 lib/navi.rb