Skip to content

Commit

Permalink
feat: add more examples
Browse files Browse the repository at this point in the history
  • Loading branch information
danielgtaylor committed Nov 2, 2023
1 parent 8ed9f46 commit 5eb898a
Show file tree
Hide file tree
Showing 5 changed files with 182 additions and 334 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,18 +81,18 @@ import (

// Options for the CLI.
type Options struct {
Port int `help:"Port to listen on" default:"8888"`
Port int `help:"Port to listen on" short:"p" default:"8888"`
}

// GreetingInput represents the greeting operation request.
type GreetingInput struct {
Name string `path:"name" doc:"Name to greet"`
Name string `path:"name" maxLength:"30" example:"world" doc:"Name to greet"`
}

// GreetingOutput represents the greeting operation response.
type GreetingOutput struct {
Body struct {
Message string `json:"message" doc:"Greeting message" example:"Hello, world!"`
Message string `json:"message" example:"Hello, world!" doc:"Greeting message"`
}
}

Expand Down
295 changes: 0 additions & 295 deletions examples/cmd/main.go

This file was deleted.

Loading

0 comments on commit 5eb898a

Please sign in to comment.