Tips on adding JSON output to your CLI app
Honestly I do not really understand this idea because, AFAIK, JSON was designed for Javascript in a web browser.  By and large, Javascript-enabled web browser expect access to generous amounts of memory.  This is not the case for the common UNIX userland programs.  These programs do not expect large amounts of memory and many are written with the intent that they may be used to process text line-by-line.  This JSON idea reminds me of Windows "PowerShell".  Microsoft actually has to limit how much memory can be used by the shell.  Why is that.<p><a href="https://devblogs.microsoft.com/scripting/learn-how-to-configure-powershell-memory/" rel="nofollow">https://devblogs.microsoft.com/scripting/learn-how-to-config...</a><p>One of the things I like most about the UNIX userland is that I can use small programs to edit vary large files, without needing lots of memory.  I want programs that are designed to accomodate the possibility of line-by-line processing.<p>If the intent is to make output network friendly, maybe something like netstrings is useful.  Easy to parse.  Low memory footprint.<p>Seems to me this JSON idea is not designed to improve performance, agility or resource efficiency but to ignore the UNIX example in favour of a different, slower, approach that is <i>perceived</i> as easier for some people to use.  Namely those who do not want to spend the time to learn how to use an existing, faster solution with lower resource requirements.