Sha256: 5959736b40c07f0806566267a3a885e5e43c33f40743e1a87bf7cd364280b5f8
Contents?: true
Size: 1.03 KB
Versions: 2
Compression:
Stored size: 1.03 KB
Contents
# DuckPuncher Currently have the following punches in our repertoire: * Array#m - alias for `map(&:)`, usage: `[1].m(:succ)` * Array#get - usage: `[].methods.get('ty?') #=> [:empty?]` * Hash#seek - usage: `{a: 1, b: {c: 2}}.seek(:b, :c) #=> 2` * Numeric#to_currency - usage: `25.245.to_currency #=> '25.25'` * Numeric#to_duration - usage `10_000.to_duration #=> '2 h 46 min'` * Numeric#to_time_ago - usage `10_000.to_time_ago #=> '2 hours ago'` * Numeric#to_rad - usage `10.15.to_rad #=> 0.17715091907742445` * String#pluralize - usage `'hour'.pluralize(2) #=> 'hours'` ## Installation Add this line to your application's Gemfile: gem 'duck_puncher' And then execute: $ bundle Or install it yourself as: $ gem install duck_puncher ## Usage TODO: Write usage instructions here ## Contributing 1. Fork it 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Add some feature'`) 4. Push to the branch (`git push origin my-new-feature`) 5. Create new Pull Request
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
duck_puncher-1.0.0 | README.md |
duck_puncher-0.2.0 | README.md |