tower-embed
This crate provides a tower service designed to provide embedded static
assets support for web application. This service includes the following HTTP features:
- Support for GET and HEAD requests
Content-Typeheader generation based on file MIME type guessed from extension.ETagheader generation and validation.Last-Modifiedheader generation and validation.
In debug mode, assets are served directly from the filesystem to facilitate
rapid development. Both ETag and Last-Modified headers are not generated in
this mode.
Example
use Router;
use ;
;
async
License
Licensed under either of Apache License 2.0 or MIT license at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.