Visualize Tries
Output Readme Download Replit Sel. & Copy Full

About

This repl creates a tree that is pruned to only show the possible completions of the inputted text.

To view this on TripleLog, click here.

HTML

The HTML is a simple input to change a string of text with an SVG that displays the trie tree.

CSS

Add CSS by editing the style.css file that is linked to in the head section or inline edit the style section in the head.

JavaScript

The script.js file generates a trie and converts it to a D3 tree. Then as the user types, the tree is pruned to eliminate the strings that are no longer possible.

Edit the wordsMap json object to change the list of strings to search for.