Skip to content

gabynaiman/string_ext

Repository files navigation

StringExt

Gem Version Build Status Coverage Status Code Climate

String utils for accented and special chars

Installation

Add this line to your application's Gemfile:

gem 'string_ext'

And then execute:

$ bundle

Or install it yourself as:

$ gem install string_ext

Usage

StringExt.downcase 'ÁÉÍÓÚÑ' # => 'áéíóúñ'
StringExt.upcase 'áéíóúñ' # => 'ÁÉÍÓÚÑ'
StringExt.unaccented 'áÉíÓú' # => 'aEiOu'
include StringExt
downcase 'ÁÉÍÓÚÑ' # => 'áéíóúñ'
upcase 'áéíóúñ' # => 'ÁÉÍÓÚÑ'
unaccented 'áÉíÓú' # => 'aEiOu'
module MyModule
  extend StringExt
  downcase 'ÁÉÍÓÚÑ' # => 'áéíóúñ'
  upcase 'áéíóúñ' # => 'ÁÉÍÓÚÑ'
  unaccented 'áÉíÓú' # => 'aEiOu'
end

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/gabynaiman/string_ext.

License

The gem is available as open source under the terms of the MIT License.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages