1.0.1 • Published 9 years ago
refjs v1.0.1
ref.js
Pass-by-reference functionality in JavaScript
Installation
npm install --save refjs
Example
var ref = require('refjs');
var foo = new ref(0);
console.log(foo.value);
function (x) { x.value = 5; }(foo);
console.log(foo.value);
Output for this example should be as follows:
0
5