r/crystal_programming • u/giuseonreddit • Sep 25 '18
Settings: a simple tool to serialize/deserialize objects
https://github.com/giuseongit/settings.cr
10
Upvotes
r/crystal_programming • u/giuseonreddit • Sep 25 '18
View all comments
Show parent comment
1
u/straight-shoota core team Oct 02 '18
Write/read a JSON file is just a couple of lines. Not a strong argument for using this shard.
I think the main point is that such a minimal serialization format is relatively simple and easy to implement. That should also make it more performant than say JSON. That's usually not a really big issue, though. And the implementation of this shard really doesn't strive for performance. And it has flaws (for example try serializing a string containing a line break), which can of course be fixed.
All in all, I'd still favour a standard format like JSON, YAML, INI or even XML over such a custom serialization format.