woah what
This commit is contained in:
1 parent
ed38899362
commit
73278074c5
9 files changed
+98
-10
No files matched your search
+1
-1
@@ -18,7 +18,7 @@ macro_rules! hehe {
|
||||
}
|
||||
|
||||
hehe! {
|
||||
file HOME_2_HTML "../static/home_2.html"
|
||||
file HOME_2_HTML "../static/index.html"
|
||||
folder home_2 {
|
||||
file DOM_JS "../static/home_2/dom.js"
|
||||
file LEASES_JS "../static/home_2/leases.js"
|
||||
|
||||
+6
-3
@@ -20,12 +20,15 @@ use std::io;
|
||||
#[cfg(target_os = "linux")]
|
||||
#[tokio::main]
|
||||
async fn entry() -> io::Result<()> {
|
||||
use crate::route::{api_router, home_2, home_2_route};
|
||||
use crate::route::api_router;
|
||||
use axum::routing::get_service;
|
||||
use tower_http::services::ServeDir;
|
||||
|
||||
let app = Router::new()
|
||||
// .route("/home", get(home))
|
||||
.route("/", get(home_2))
|
||||
.merge(home_2_route())
|
||||
// .route("/", get(home_2))
|
||||
// .merge(home_2_route())
|
||||
.nest_service("/", get_service(ServeDir::new("static")))
|
||||
// .route("/status", get(get_status_2))
|
||||
.nest("/api", api_router());
|
||||
|
||||
|
||||
+1
-1
@@ -39,7 +39,7 @@ pub fn home_2_route() -> Router {
|
||||
"/home_2/styles.css",
|
||||
get(|| async {
|
||||
(
|
||||
[
|
||||
[
|
||||
(header::CONTENT_TYPE, "text/css; charset=utf-8"),
|
||||
(header::CACHE_CONTROL, "public, max-age=300"),
|
||||
],
|
||||
|
||||
Reference in new issue
Block a user