uce/site/doc/pages/route_path_normalize.txt
2026-06-16 12:21:31 +00:00

19 lines
458 B
Plaintext

:sig
String route_path_normalize(String path)
:see
>uri
route_path_sanitize
route_path_is_safe
request_query_path
request_query_route
:content
Trims whitespace and removes leading/trailing `/` from a route path without deciding whether the path is safe.
For route data that may be used to compose file paths, prefer `route_path_sanitize()` or runtime-populated `context.params["ROUTE_PATH"]`.
:example
print(route_path_normalize("/docs/index/"), "\n");