Json-parser written in JavaScript