mirror of https://github.com/rwf2/Rocket.git
14 lines
213 B
Rust
14 lines
213 B
Rust
|
#![feature(plugin)]
|
||
|
#![plugin(rocket_codegen)]
|
||
|
|
||
|
extern crate rocket;
|
||
|
|
||
|
#[get("/")]
|
||
|
fn hello() -> &'static str {
|
||
|
"Hello, world!"
|
||
|
}
|
||
|
|
||
|
fn main() {
|
||
|
rocket::ignite().mount_and_launch("/hello", routes![hello]);
|
||
|
}
|