Class: Unbelievable::Lorem

Inherits:
Generator show all
Defined in:
lib/unbelievable/lorem.rb

Instance Method Summary collapse

Methods inherited from Generator

#initialize

Constructor Details

This class inherits a constructor from Unbelievable::Generator

Instance Method Details

#story(words) ⇒ Object



9
10
11
12
# File 'lib/unbelievable/lorem.rb', line 9

def story(words)
  terms = words.map { |size| dictionary.pick(size) }
  wrap_text terms.join(" ").capitalize
end