Skip to content

Modularized loader syntax

Compare
Choose a tag to compare
@greencoda greencoda released this 24 Apr 07:55
· 4 commits to master since this release
e9e59a4

This release features a new modularized loader syntax which allows users to load config values via the following new syntax, instead of first-level methods on the configSet struct:

configSet := confiq.New()

if err := configSet.Load(
    confiqjson.Load().FromFile("./config.json"),
    confiq.WithPrefix("somePrefix"),
); err != nil {
    log.Fatal(err)
}