module Detour
Constants
- VERSION
Public Class Methods
config()
click to toggle source
# File lib/detour.rb, line 24 def self.config @config ||= Detour::Configuration.new end
configure() { |config| ... }
click to toggle source
Allows for configuration of Detour::Feature, mostly intended for defining groups:
@example
Detour.configure do |config| config.define_user_group :admins do |user| user.admin? end end
# File lib/detour.rb, line 17 def self.configure(&block) ActionDispatch::Reloader.to_prepare do yield Detour.config Detour.config.flaggable_types.each { |f| f.constantize } end end