pub fn file_server(root: String) -> impl HandlerExpand description
Serve files from the filesystem rooted at root.
Port of Go’s http.FileServer.
The URL path is joined to root to form the filesystem path. Directory
listings are not supported — a 403 is returned for directories. File reads
are performed synchronously within the goroutine (no extra goroutine spawn
needed since each connection already has its own goroutine).