Hacker News new | ask | show | jobs
by spaux 4582 days ago
Why would you use this over JSON? Looks like if your application makes heavy use of arrays, space will take way more 'space' than JSON.

eg: {"test":[1,2,3]} vs test\n item 1\n item 2\n item 3\n

1 comments

Space is great for building DSLs on top of. You often want to have additional types that your domain specific code recognizes. For example, your example could also be written in a DSL that is also valid space:

``` test [1,2,3] ```

Space is best for cases where you have small to medium sized objects that are often viewed/edited by humans, such as APIs, config files, schemas, or database objects.