const Trie = require('ds-trie');
const assert = require('assert');
const t = new Trie();
t.addElement(['path', 'a'], 'something');
t.addElements(['path', 'b'], ['other', 'stuff']);
t.removeElement(['path', 'b'], 'other');
t.addElement(['path'], 'root');
assert.deepStrictEqual(t.collect(['path', 'b']), ['stuff', 'root']);
-
Notifications
You must be signed in to change notification settings - Fork 0
kendru/ds-trie
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Dead-simple trie data structure in JavaScript
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published