View Source Hologram.Router.SearchTree (hologram v0.2.0)

Summary

Functions

Adds route info for the given URL path to the search tree by creating all nodes related to that URL path.

Matches the given URL path against the search tree.

Functions

add_route(search_tree, url_path, page_module)

Adds route info for the given URL path to the search tree by creating all nodes related to that URL path.

match_route(search_tree, url_path)

@spec match_route(Hologram.Router.SearchTree.Node.t(), String.t()) :: atom() | false

Matches the given URL path against the search tree.