Add parameter for pretty-printing the resulting JSON string

Uses JSON.stringify's third parameter, "space". More information at [MDN docs](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify).  
Also bumped the version number according to semver; "add functionality in a backwards-compatible manner".