@vect/callable
v0.6.13
Published
An array util tool
Downloads
36
Readme
@vect/callable
Make a class callable by inherit the class Callable.
Features
- ES2015 syntax
Install
$ npm install @vect/callable
Usage
import { Callable } from '@vect/callable'
class CallableClass extends Callable {
constructor (a, b) {
super(row => this.a + this.b + row)
this.a = a
this.b = b
}
}
const callableClass = new CallableClass(5, 4)
console.log(callableClass(3)) // 12