pub struct App<S, E>where
S: ContextExt<Context<S>>,{ /* private fields */ }
Expand description
build an axum::Router
with all routes required for API and admin interface
Implementations§
Source§impl<S, SE> App<S, SE>where
S: ContextExt<Context<S>> + 'static,
impl<S, SE> App<S, SE>where
S: ContextExt<Context<S>> + 'static,
Source§impl<S, SE> App<S, SE>where
S: ContextExt<Context<S>> + 'static,
impl<S, SE> App<S, SE>where
S: ContextExt<Context<S>> + 'static,
pub fn with_mdeditor(self, config: EditorConfig) -> Self
Source§impl<S, E> App<S, E>where
S: ContextExt<Context<S>> + 'static,
impl<S, E> App<S, E>where
S: ContextExt<Context<S>> + 'static,
pub fn with_state(self, data: S) -> App<S, S>
Source§impl<S, E> App<S, E>where
S: ContextExt<Context<S>> + 'static,
Include the given assets when loading the localized messages
upon a request.
They can then be accessed in any render functions called by
this library (e.g. Column::render
or Input::render_input
).
Note: The domain in these functions will still be "derived_cms"
,
so make sure to add the localized messages to the correct domain
file in the assets.
impl<S, E> App<S, E>where
S: ContextExt<Context<S>> + 'static,
Include the given assets when loading the localized messages
upon a request.
They can then be accessed in any render functions called by
this library (e.g. Column::render
or Input::render_input
).
Note: The domain in these functions will still be "derived_cms"
,
so make sure to add the localized messages to the correct domain
file in the assets.
pub fn include_localizations( self, assets: impl I18nAssets + Send + Sync + 'static, ) -> App<S, E>
Trait Implementations§
Auto Trait Implementations§
impl<S, E> Freeze for App<S, E>where
E: Freeze,
impl<S, E> !RefUnwindSafe for App<S, E>
impl<S, E> Send for App<S, E>where
E: Send,
impl<S, E> Sync for App<S, E>where
E: Sync,
impl<S, E> Unpin for App<S, E>where
E: Unpin,
impl<S, E> !UnwindSafe for App<S, E>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more