fuzzy-proxy
v0.0.13
Published
Fuzzy match keys on objects
Readme
fuzzy-proxy
Fuzzy match keys on objects
FuzzyProxy
Kind: global class
new FuzzyProxy(objectToProxy)
FuzzyProxy - Creates an object with fuzzy matching capabilities
Returns: object - Fuzzy proxied object
| Param | Type | Description | | --- | --- | --- | | objectToProxy | object | Object to apply fuzzy proxying to |
Example
const bestObjectEver = new FuzzyProxy({
tripleDouble(number) {
return number * 3 * 2;
},
unicorn: '🦄',
});
bestObjectEver.uni
// → '🦄'
bestObjectEver.tripleD(13)
// → 78Scripts
test – run the tests
npm run testcoverage – generate and view code coverage as HTML
npm run coveragelint – lint the codebase
npm run lintreadme – generate the README
npm run readmecompile – compile the code
npm run compileLicense
MIT @ Flip
