New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to control whether to generate inline list/map or not? #2
Comments
Currently this is not possible. I'm thinking a good API for this might be something like a |
There is a small problem with this solution: types like Map/List may sometimes need to be inlined and sometimes don't. But I think it's fine to let users handle these themselves. Also, I have some suggestions:
By the way, thanks for your library. Without it, I would have to introduce a huge dependency just for TOML. |
Separated the invalid TOML generation part into its own issue (#12), so this issue can focus on the configurability part. |
c2678aa introduces an interface for configuring serialization. It doesn't yet allow per-type configuration yet, but otherwise it covers most aspects of table/inline/multiline syntax. What do you think? It does not change the default to prefer inline syntax, mostly to avoid changing defaults people might have come to expect. |
Closing as fixed since there seem to be no complaints about the merged solution. |
My data classes:
I would like to generate files like this:
But it generates this:
So is there a way to control whether to generate inline list/map or not?
The text was updated successfully, but these errors were encountered: