Skip to content

Commit

Permalink
Update godoc
Browse files Browse the repository at this point in the history
  • Loading branch information
kkyr committed May 13, 2020
1 parent 43e5e10 commit 8bfb7a1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions fig.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,16 @@ const (
// A field can be marked as required by adding a `required` key in the field's struct tag.
// If a required field is not set by the configuration file an error is returned.
//
// type config struct {
// Env string `fig:"env,required"` // or `fig:",required"`
// type Config struct {
// Env string `fig:"env" validate:"required"` // or just `validate:"required"`
// }
//
// A field can be configured with a default value by adding a `default=value` in the field's
// struct tag.
// A field can be configured with a default value by adding a `default` key in the
// field's struct tag.
// If a field is not set by the configuration file then the default value is set.
//
// type config struct {
// Level string `fig:"level,default=info"` // or `fig:",default=info"`
// Level string `fig:"level" default:"info"` // or just `default:"info"`
// }
//
// A single field may not be marked as both `required` and `default`.
Expand Down

0 comments on commit 8bfb7a1

Please sign in to comment.