must-have-func

v1.0.0
little module to mandate functions on an object
must have object require key value nested function functions and 2 more...

must-have-func

what?

A little module to mandate functions on an object.
Will throw error if listed function is not present or is not a function.

install

npm install must-have-func --save

use

var mustHave = require('must-have-func');
mustHave(myObject, "getName", "getEmail");
mustHave(myObject, "works.with.nested.functions.doSomething");

npm i must-have-func

Metadata

  • ISC
  • Whatever
  • Philip Morris
  • released 8/30/2016

Downloads

Maintainers