0.0.2 • Published 8 years ago

obfilter v0.0.2

Weekly downloads
2
License
MIT
Repository
github
Last release
8 years ago

Obfilter

A small library to compare objects using simple rules

Installation

npm install obfilter --save

Usage

var obfilter = require('obfilter');

var structureRule = {
	structure: true
};

var matchSome = {
	match:{
		some:true
	}
};

var matchAll = {
	match:{
		all:true
	}
};

var test = {
	contributors:["Andrew","Batman"]
};

var match = {
	contributors:["Batman"]
};


obfilter.filterObject(test,match,matchSome); // returns true
obfilter.filterObject(test,match,matchAll); // returns false

Tests

npm test

Contributing

Whatever bro

Release History

  • 0.0.1 Initial release
0.0.2

8 years ago

0.0.1

8 years ago