Hacker News new | ask | show | jobs
by rienbdj 4 days ago
There are compile-to-yaml config languages
1 comments

Any good ones people would recommend?
In my experience I tried a few and kept returning to just Typescript with a good YAML serializer library. Most of what you need in YAML programming is "Typed JSON" and Typescript is an excellent "Typed JSON" and "Typed JSON modularization and merger tool". Then just a little bit of glue code to pass your finished "Typed JSON" into a YAML serializer, depending on any "complex" YAML features you might need.
Not a bad solution at all. It does require some discipline to write deterministic templates etc. though.