Open aspiers opened 6 years ago
Ahh I see, you have to require 'word_wrap'
first. I'd argue that's a usability bug ;-)
To summarize, both requires are needed. This works:
irb(main):001:0> require "word_wrap"
=> true
irb(main):002:0> require "word_wrap/core_ext"
=> true
irb(main):003:0> "123 456 789".wrap 5
=> "123\n456\n789\n"
@aspiers I think this issue can be closed
Same issue on Ruby 2.4.1 and 2.2.1. Looks like some module namespacing issue.