1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
//! Shuttle service integration for the Salvo web framework.
//! ## Example
//! ```rust,no_run
//! use salvo::prelude::*;
//!
//! #[handler]
//! async fn hello_world(res: &mut Response) {
//! res.render(Text::Plain("Hello, world!"));
//! }
//!
//! #[shuttle_runtime::main]
//! async fn salvo() -> shuttle_salvo::ShuttleSalvo {
//! let router = Router::with_path("hello").get(hello_world);
//!
//! Ok(router.into())
//! }
//!
//! ```
use Error;
use SocketAddr;
/// A wrapper type for [salvo::Router] so we can implement [shuttle_runtime::Service] for it.
;
/// The return type that should be returned from the [shuttle_runtime::main] function.
pub type ShuttleSalvo = ;