Registry / utility / mcuadros-go-lookup

mcuadros-go-lookup

JSON →
library0.0.0-20230627150232-5415b5b32da8gogounverified

Small library on top of reflect for making lookups to structs or maps using a simple DSL.

go get github.com/mcuadros/go-lookup
INSTALL
IMPORT
SIG · MCUADROS-GO-LOOKUP
M
mcuadros-go-lookup
utilitygov0.0.0-20230627150232-5415b5b32da8
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

lookup
github.com/mcuadros/go-lookup

Looks up a field in a struct using a simple path.

package main import ( "fmt" "github.com/mcuadros/go-lookup" ) func main() { type Person struct { Name string } p := Person{Name: "Alice"} result, _ := lookup.Lookup(p, "Name") fmt.Println(result) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.0.0-20230627150232-5415b5b32da8latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources