added crates to public project, made api structure
This commit is contained in:
15
backend/public/src/routes/root.rs
Normal file
15
backend/public/src/routes/root.rs
Normal file
@ -0,0 +1,15 @@
|
||||
use axum::{
|
||||
http::StatusCode,
|
||||
response::{Html, IntoResponse},
|
||||
};
|
||||
|
||||
pub struct RootRoute;
|
||||
impl RootRoute {
|
||||
pub async fn root() -> Html<&'static str> {
|
||||
Html("<p>Copyright Wyatt J. Miller 2024</p>")
|
||||
}
|
||||
|
||||
pub async fn not_found() -> impl IntoResponse {
|
||||
(StatusCode::NOT_FOUND, "¯\\_(ツ)_/¯")
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user