defaultloader

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 9, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Loader

type Loader struct {
	// contains filtered or unexported fields
}

func New

func New(opts ...Option) *Loader

func (Loader) Load

func (l Loader) Load(ctx context.Context, to any) error

func (Loader) LoadChu

func (l Loader) LoadChu(ctx context.Context, to any, opts ...loader.Option) error

type Option

type Option func(*option)

func WithHooks

func WithHooks(hooks ...loader.HookFunc) Option

WithHooks sets the hooks for the environment loader.

  • if return type matches the field type, return value is assigned to the field

func WithTagName

func WithTagName(tagName string) Option

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL