1000.0.0 • Published 6 years ago

noop3 v1000.0.0

Weekly downloads
132
License
MIT
Repository
github
Last release
6 years ago

◻️ Supreme nothingness

Build Status Coverage Status

npm.io

Install

$ npm install noop3

Usage

const noop = require('noop3');

function unicorn(fn) {
	fn = fn || noop;
	return fn('unicorn');
}
unicorn();

// Also compatible with non-mythical single horned creatures
function narwhal(fn) {
	fn = fn || noop;
	return fn('narwhal');
}
narwhal();

// Using the noop factory
const fn = require('noop3/factory');
const rainbow = fn();
const flowers = fn();
console.log(rainbow === flowers);
//=> false

rainbow();
//=> undefined

Related

License

MIT © Sindre Sorhus