Module: Louisville::Slugger::ClassMethods
- Defined in:
- lib/louisville/slugger.rb
Instance Method Summary collapse
Instance Method Details
#louisville_config ⇒ Object
24 25 26 |
# File 'lib/louisville/slugger.rb', line 24 def louisville_config @louisville_slugger || (superclass.respond_to?(:louisville_config) ? superclass.louisville_config : nil) end |
#slug(field, options = {}) ⇒ Object
18 19 20 21 22 |
# File 'lib/louisville/slugger.rb', line 18 def slug(field, = {}) @louisville_slugger = ::Louisville::Config.new(field, ) @louisville_slugger.hook!(self) @louisville_slugger end |