strict-method
v0.0.8
Published
strict method
Downloads
4
Readme
strictmethod
strict method
example
var m = require("strict-method");
var user = {
_name:"leo",
_age:22,
change:m(String,{min:5},Number,function(name,age){
this._name = name;
this._age = age;
})
}
user.change("brighthas",28); // not error.
user.change("bri",28); // throw error! must min > 5