Categorygithub.com/go-saas/lazy
repositorypackage
1.0.0
Repository: https://github.com/go-saas/lazy.git
Documentation: pkg.go.dev

# README

Go generic lazy

go get -u github.com/go-saas/lazy
import (
    "context"
    "github.com/go-saas/lazy"
)

type A struct {
	
}

lazyA := lazy.New[*A](func(ctx context.Context) (*A, error){
	return &A{}
})
a,_ := lazyA.Value(context.Background())