Documentation
¶
Index ¶
- func CustomSchema[T any](target T) ([]byte, error)
- func HasAppConfig[T any](target T) error
- func MustLoadConfigInto[T any](ctx context.Context, into T) (context.Context, T)
- func MustSetupConfigAndLogging(ctx context.Context) context.Context
- func MustSetupConfigAndLoggingInto[T any](ctx context.Context, into T) (context.Context, T)
- type App
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CustomSchema ¶ added in v0.7.0
Generates json schema for custom config which embeds *config.AppConfig into it Panics if no *config.AppConfig is embedded into custom config type
See swaggest/jsonschema-go for struct tag docs
func HasAppConfig ¶ added in v0.7.0
func MustLoadConfigInto ¶ added in v0.3.1
Used to unmarshal config and environment into a custom type that overloads *config.AppConfig. Will perform normal env substitutions for AppConfig, but env overrides for custom type are up to the caller.
func MustSetupConfigAndLogging ¶
Helper function to return a context loaded up with config.AppConfig and a logger
Types ¶
Click to show internal directories.
Click to hide internal directories.