Make static file links typesafe
This commit is contained in:
parent
e64ea7ac12
commit
1ead78d44f
4 changed files with 53 additions and 9 deletions
|
|
@ -32,3 +32,6 @@ pub async fn static_handler(uri: Uri) -> impl IntoResponse {
|
|||
let path = uri.path().trim_start_matches('/').to_string();
|
||||
StaticFile(path)
|
||||
}
|
||||
|
||||
// Constants for each static file, generated by the build script.
|
||||
include!(concat!(env!("OUT_DIR"), "/static.rs"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue