Sometimes building a routing tree by hand can be very inconvenient. Hence, there is the path, which is a parameter to the route function, that is processed to build routing trees. First, it is split into path segments by the / delimiter. Each segment generates a nested routing node. These two variants are equivalent:
// Variant 1 route("/foo/bar") { … }
// Variant 2 route("/foo") { route("bar") { … } }