I can understand the sentiment and would 100% agree for programming languages.
But personally I actually like that it encourages a flat structure, because you do not want to be yakshaving the structure of your config file. Too much nesting means you will sooner or later run into configuration keys being nested under the wrong category, because your project context changed over time.
And well, as I’ve argued in a few other comments already, I think non-techie users have a disproportionally simpler time when no nesting is used. They understand the concept of a heading and then just adding a line underneath the appropriate heading is really intuitive.
You can just tell them to add the line certificate="/tmp/cert.crt" under [network.tls] and they will find a line in their config file which actually reads [network.tls] and they can just paste that line as-is.
You need some awkward explanation where they should nest it, or an explanation that e.g. “network.tls” translates to nesting.
They will ask whether they should indent the line you sent them.
Well, and it’s also surprisingly difficult to explain between which braces they should put the text, and that’s at the end of the braces, but not after the braces etc., if you’re talking to them on a call.
It’s not even that I’m completely enamored with TOML, but this aspect is certainly growing on me…
I can understand the sentiment and would 100% agree for programming languages.
But personally I actually like that it encourages a flat structure, because you do not want to be yakshaving the structure of your config file. Too much nesting means you will sooner or later run into configuration keys being nested under the wrong category, because your project context changed over time.
And well, as I’ve argued in a few other comments already, I think non-techie users have a disproportionally simpler time when no nesting is used. They understand the concept of a heading and then just adding a line underneath the appropriate heading is really intuitive.
You can just tell them to add the line
certificate="/tmp/cert.crt"under[network.tls]and they will find a line in their config file which actually reads[network.tls]and they can just paste that line as-is.With nesting, they’d need to add it under here:
network: { tls: { certificate: "/tmp/cert.crt" } }Which means:
It’s not even that I’m completely enamored with TOML, but this aspect is certainly growing on me…