Description

ServeFile returns HTTP response containing compressed file contents from the given path.

HTTP response may contain uncompressed file contents in the following cases:

* Missing 'Accept-Encoding: gzip' request header.
* No write access to directory containing the file.

Directory contents is returned if path points to directory.

Use ServeFileUncompressed is you don't need serving compressed file contents.

See also RequestCtx.SendFile.

ServeFile is referenced in 2 repositories

github.com/valyala/fasthttp

...