use :.. instead of :...

This commit is contained in:
Evan Almloff committed 2023-07-18 16:34:27 -07:00
1 parent f2c4233ef4
commit 61e9fd9973
11 files changed
+15 -15

No files matched your search

+1 -1
View File
@@ -8,7 +8,7 @@ enum Route {
#[route("/")]
Home {},
// PageNotFound is a catch all route that will match any route and placing the matched segments in the route field
#[route("/:...route")]
#[route("/:..route")]
PageNotFound { route: Vec<String> },
}
// ANCHOR_END: router
+1 -1
View File
@@ -7,7 +7,7 @@ use dioxus_router::prelude::*;
#[rustfmt::skip]
enum Route {
// segments that start with :... are catch all segments
#[route("/blog/:...segments")]
#[route("/blog/:..segments")]
BlogPost {
// You must include catch all segment in child variants
segments: Vec<String>,
+1 -1
View File
@@ -26,7 +26,7 @@ enum Route {
#[end_layout]
#[end_nest]
#[end_layout]
#[route("/:...route")]
#[route("/:..route")]
PageNotFound {
route: Vec<String>,
},
+1 -1
View File
@@ -30,7 +30,7 @@ enum Route {
#[redirect("/", || Route::BlogList {})]
#[redirect("/:name", |name: String| Route::BlogPost { name })]
#[end_nest]
#[route("/:...route")]
#[route("/:..route")]
PageNotFound {
route: Vec<String>,
},
+1 -1
View File
@@ -11,7 +11,7 @@ enum Route {
#[route("/")]
Home {},
#[end_layout]
#[route("/:...route")]
#[route("/:..route")]
PageNotFound { route: Vec<String> },
}
// ANCHOR_END: router
+1 -1
View File
@@ -7,7 +7,7 @@ use dioxus_router::prelude::*;
enum Route {
#[route("/")]
Home {},
#[route("/:...route")]
#[route("/:..route")]
PageNotFound { route: Vec<String> },
}
+1 -1
View File
@@ -11,7 +11,7 @@ enum Route {
#[route("/")]
Home {},
#[end_layout]
#[route("/:...route")]
#[route("/:..route")]
PageNotFound { route: Vec<String> },
}
// ANCHOR_END: router