Show HN: Xfer, a data-transfer language
github.com
github.com
JSON clearly wins this comparison because people can look at the JSON and guess what it means. People aren't going to go for a more complicated format that makes less sense. I personally prefer Clojure's EDN when it comes to data formats just because it looks nicer and removes redundant syntax. I don't think there's much to be improved upon from there.
You mean `\ad` , obviously. (You see where I'm going with this?)
The biggest issue I see with JSON today is the inability to self reference values. Data duplication overhead is high, and deserializing doesn't work as expected if you want two objects to be reference equal.
Also, nitpick: that syntax would be a grind to write manually vs JSON.
I haven't thought about self-reference. I'll pin that to the list of things to play with. For me, it was comments, placeholders, and typing, and those drove the syntax evolution, especially with regard to nesting of elements. Trust me, you would have really hated the first couple of iterations.
Now, unfiltered first thoughts...
Have you used SOAP RPC and is it clear why the industry (outside of banking and financial services that depend on correctness!) largely shifted to JSONic REST?
At first exposure to this, the delimiters feel like line noise, as if SOAP and a lineprinter got together and said, "How could this offer less utility while being more opaque?"
There's a cognitive tax on something being unlike other things, which is why so many substitutions end up adopting handlebars/mustache type syntax, or so many things look like INI/TOML/YAML/etc.
Have you looked at JSON5, XML + XSLT, JSONNET and the like? What about JSON Schema and similar? ( https://json-schema.org/understanding-json-schema/reference/... )
Not saying any of those are be-all end-all, they are not. But it would be super helpful to have a "Why not X" page on your README that shows you've considered SOTA across the landscape, and why that doesn't work for you. See, for example: https://hitchdev.com/hitchstory/why-not/
I have used SOAP on some large projects, and I wasn't a fan. It just feels like, with JSON, the pendulum swung pretty far the other way. Thanks for those references to other standards; I'll look those over and see what I can learn.
I think where JSON really chafes me is in places like configuration files, where I'd like a little finer control and more features, and Xfer has probably shifted more in that direction. It's certainly nowhere near ready for production, and I think it will probably remain an experiment, but it's been fun and educational.