const-func
Create a function always returning a constant
Install
npm install --save const-func
Usage
const alwaysUndefined = // => undefined const always3 = // => 3 const alwaysHi = // => 'hi'
API
always(arg)
Returns a function that always returns a constant value.
arg
type: *
default: undefined
The constant value to always return from the constant function.
LICENSE
MIT © Dustin Specker