mirror of
https://github.com/gofiber/fiber.git
synced 2025-02-23 12:03:49 +00:00
Update README.md
This commit is contained in:
parent
dbdfdc5fbe
commit
5f1b711fd8
8
.github/README.md
vendored
8
.github/README.md
vendored
@ -162,14 +162,14 @@ func main() {
|
||||
|
||||
// GET /plantae/prunus.persica
|
||||
app.Get("/plantae/:genus.:species", func(c *fiber.Ctx) {
|
||||
c.Params("genus") // => prunus
|
||||
c.Params("species") // => persica
|
||||
fmt.Printf("Genius: %s, Species: %s", c.Params("genus"), c.Params("species"))
|
||||
// => Genius: prunus, Species: persica
|
||||
})
|
||||
|
||||
// GET /flights/LAX-SFO
|
||||
app.Get("/flights/:from-:to", func(c *fiber.Ctx) {
|
||||
c.Params("from") // => LAX
|
||||
c.Params("to") // => SFO
|
||||
fmt.Printf("From: %s, To: %s", c.Params("from"), c.Params("to"))
|
||||
// => From: LAX, To: SFO
|
||||
})
|
||||
|
||||
// GET /api/register
|
||||
|
Loading…
x
Reference in New Issue
Block a user