Serializing Typesafe Config objects
Try this:
config.root().render(ConfigRenderOptions.concise())
Of course you can also adjust a few parameters, for example:
val renderOptions = ConfigRenderOptions
.defaults()
.setOriginComments(false)
.setComments(false)
.setFormatted(true)
println(config.root().render(renderOptions))