Basic Structure

Configuration files are standard YAML files:

# config.yaml
server:
  host: localhost
  port: 8080

database:
  url: postgres://localhost/app

Code accesses configuration settings using dot-separated configuration paths.

For instance, to get the server port from the above configuration, use config.get("server.port"). To check whether a value exists before retrieving it, use config.has("database.url"), and to fall back to a default when a path is not set, pass it as the second argument, e.g., config.get("server.timeout", 30).