Adds word_count method to string.
"Some String Content".word_count # => 3
Add this line to your application's Gemfile:
gem 'count_words'
And then execute:
$ bundle
Or install it yourself as:
$ gem install count_words
The gem is available as open source under the terms of the MIT License.