remove the extract macro
This commit is contained in:
1 parent
0636e94f37
commit
c6ddee6f21
4 files changed
+9
-68
No files matched your search
@@ -47,8 +47,7 @@ pub mod prelude {
|
||||
pub use crate::server_context::Axum;
|
||||
#[cfg(feature = "ssr")]
|
||||
pub use crate::server_context::{
|
||||
extract_server_context, server_context, DioxusServerContext, FromServerContext,
|
||||
ProvideServerContext,
|
||||
extract, server_context, DioxusServerContext, FromServerContext, ProvideServerContext,
|
||||
};
|
||||
pub use crate::server_fn::DioxusServerFn;
|
||||
#[cfg(feature = "ssr")]
|
||||
|
||||
@@ -117,7 +117,7 @@ pub fn server_context() -> DioxusServerContext {
|
||||
/// Extract some part from the current server request.
|
||||
///
|
||||
/// This function will only provide the current server context if it is called from a server function or on the server rendering a request.
|
||||
pub async fn extract_server_context<E: FromServerContext<I>, I>() -> Result<E, E::Rejection> {
|
||||
pub async fn extract<E: FromServerContext<I>, I>() -> Result<E, E::Rejection> {
|
||||
E::from_request(&server_context()).await
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user