bind-right

0.6.0 • Public • Published

bind-right Build Status

JavaScript: bind arguments from the right.

Installation

npm install bind-right

Usage

require('bind-right'); // extends the function prototype
 
function createArray (/* items */) {
  return [].concat(arguments);
};
 
var thisArg = null;
var bound = createArray.bindRight(thisArg, 3,4,5);
var array = bound(1,2,3);
 
// array: [1, 2, 3, 4, 5, 6];

OMG IT EXTENDS FUNCTION???!?!@

Yes, as it should.

License

MIT

Package Sidebar

Install

npm i bind-right

Weekly Downloads

0

Version

0.6.0

License

MIT

Last publish

Collaborators

  • tjmehta