Skip to content

mtsgi/bury

Repository files navigation

Bury.js

npm MIT License code size npm downloads

v0.7 alpha version

Ruby-like methods for JavaScript

Bury.js extends the prototype of native JS objects such as String, Number and Array.

Example

[3, 3, 4, null].compact.uniq.sum // => 7
[1, 2, 3, 4].append(5).last // => 5
"Hello!".upcase.chop.reverse // => "OLLEH"
"Bury.js".gsub(/\./, '').size // => 6
3.5.floor.next // => 4
3..times(n => alert(n)) // => Try it out!

💡 View more example 💡

Getting Started

npm i buryjs
# or
yarn add buryjs

Note: All of Bury's destructive methods will be changed to non-destructive methods in a future version.