module Blocks::Configurator::ClassMethods

Public Instance Methods

configure() { |self| ... } click to toggle source
# File lib/blocks/utilities/configurator.rb, line 41
def configure
  yield self
  self.track_caller = true if lookup_caller_location
  if track_caller
    HashWithRenderStrategy.send(:prepend, HashWithCaller)
  end
end
reset_config() click to toggle source
# File lib/blocks/utilities/configurator.rb, line 29
def reset_config
  configure do |config|
    config.builder_class = Builder
    config.renderer_class = Renderer
    config.lookup_caller_location = false
    config.track_caller = false
    config.global_options = nil
    config.default_render_options_take_precedence_over_block_defaults = false
    config.collection_item_passed_to_block_as_first_arg = false
  end
end