wip: get all posts route working state

This commit is contained in:
2024-09-25 18:29:12 -04:00
parent 7842baf5f2
commit 9bd2cf373a
5 changed files with 72 additions and 43 deletions

View File

@ -46,11 +46,11 @@ async fn main() {
// build our application with some routes
let app = Router::new()
.nest("/", routes::root::RootRoute::routes())
.nest("/posts", routes::posts::PostsRoute::routes(&app_state))
.nest(
"/comments",
routes::comments::CommentsRoute::routes(&app_state),
);
.nest("/posts", routes::posts::PostsRoute::routes(&app_state));
// .nest(
// "/comments",
// routes::comments::CommentsRoute::routes(&app_state),
// );
// run it with hyper
let listener = TcpListener::bind("0.0.0.0:3000").await.unwrap();