elixir-toniq / vapor

Runtime configuration system for Elixir
MIT License
596 stars 37 forks source link

Normalize all configuration keys into paths #14

Closed keathley closed 5 years ago

keathley commented 5 years ago

We don't handle nested values well. We should convert nested values into "paths" similar to what get_in uses. For JSON and similar systems something like this:

{
  foo: {
    bar: {
      baz: 123
    }
  }
}

Would be accessed like: ["foo", "bar", "baz"].

Environment variables should be converted by their underscores. So if we have something like APP_DB_PORT we would access it like ["db", "port"].