diff options
| author | Fuwn <[email protected]> | 2022-03-26 03:14:38 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2022-03-26 03:14:38 +0000 |
| commit | 327c338786f1cca92c669adc5400997e2ad771dc (patch) | |
| tree | 5ebe0912dc4da3fbe52abf31dd1f062acce0393d /src | |
| parent | feat: working proof (diff) | |
| download | windmark-327c338786f1cca92c669adc5400997e2ad771dc.tar.xz windmark-327c338786f1cca92c669adc5400997e2ad771dc.zip | |
refactor(router): rename get to mount
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib.rs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -105,10 +105,10 @@ impl Router { /// /// ```rust /// windmark::Router::new() - /// .get("/", |_| "This is the index page!".into()) - /// .get("/test", |_| "This is a test page!".into()); + /// .mount("/", |_| "This is the index page!".into()) + /// .mount("/test", |_| "This is a test page!".into()); /// ``` - pub fn get( + pub fn mount( &mut self, route: &str, handler: fn(&TcpStream) -> String, |