fn page(req: HttpRequest) -> LocalBoxFuture<'static, Result<Page, TelescopeError>> {
        Box::pin(async move {
            // We have to double wrap this future to avoid lifetime constraint issue?
            // Or at least adding the async block seems to fix it since it moves the template.
            Page::new(&req, Self::PAGE_TITLE, Self::template()).await
        })
    }
/// Create a page containing the static content. This is also the actix handler
Create a page containing the static content. This is also the actix handler
Create a page containing the static content . This is also the actix handler
fn page(req: HttpRequest) -> LocalBoxFuture<'static, Result<Page, TelescopeError>> {
        Box::pin(async move {
            // We have to double wrap this future to avoid lifetime constraint issue?
            // Or at least adding the async block seems to fix it since it moves the template.
            Page::new(&req, Self::PAGE_TITLE, Self::template()).await
        })
    }
fn page ( req : HttpRequest ) -> LocalBoxFuture < ' static , Result < Page , TelescopeError > > { Box :: pin ( async move { // We have to double wrap this future to avoid lifetime constraint issue? // Or at least adding the async block seems to fix it since it moves the template. Page :: new ( & req , Self :: PAGE_TITLE , Self :: template ( ) ) . await } ) }
Create a page containing the static content.
Create a page containing the static content .
req
HttpRequest
req
HttpRequest