push(text) {
        let node = this.root;
        for (const ch of text) {
            let child = node.children.get(ch);
            if (child === undefined) {
                child = CharTrieNode.default();
                node.children.set(ch, child);
            }
            node = child;
        }
        node.isLeaf = true;
    }
Adds text to the trie.
@param {string} text The string to add to the trie.