trie-map

this is an implementation of trie.

Usage no npm install needed!

<script type="module">
  import trieMap from 'https://cdn.skypack.dev/trie-map';
</script>

README

Trie Map in Javascript

this is an implementation of trie.

var trie = require("trie-map");

var root = trie.createNode();

trie.setValue(root, "key1", "Hello World");
trie.setValue(root, "key2", "Hello Universe");
trie.setValue(root, "key3", "Hello Earth");

console.log(trie.getValue(root, "key2"));