cat-bookmarker/assets/node_modules/wildcard/examples/objects.js

11 lines
179 B
JavaScript
Raw Permalink Normal View History

2024-03-10 18:52:04 +00:00
var wildcard = require('..');
var testdata = {
'a.b.c' : {},
'a.b' : {},
'a' : {},
'a.b.d' : {}
};
console.log(wildcard('a.*.c', testdata));
// --> { 'a.b.c': {} }