14 ms·
Ignore the haters, and other lessons learned from creating JSON5
- bawolff 4y agoI think the only valid objection here is that calling it json5 implies that it is an offical new version of json by the same people who brought you json. That's misleading and bordering on unethical in my opinion. Everything else is a matter of taste, and who really cares.
- deleted 4y ago[deleted]
- deleted 4y ago[deleted]
- hnusersarelame 4y agoThe kind of people who leave criticism on HN are not worth listening to anyway. Most of the users of this site have no taste and think they're more brilliant / important than they actually are.
- pestaa 4y agoYour comment is so self aware, it's almost an AI. :D
- politelemon 4y agoAs someone on HN, I can't say with confidence that I resemble that remark.
- jackblemming 4y agoThere's a lot of critics, then you look at their accomplishments and it's unsurprisingly sparse.
- thrown_22 4y agoSome people get paid in money and not exposure.
- jackblemming 4y agoYou may want to find other employment if your work requires an NDA that disallows any discussion of your work, or your future opportunities to get paid in money may be limited.
- thrown_22 4y agoThey aren't. National security is like catnip for recruiters.
- froderick 4y agoI think you will find that a great diversity of minds are attracted to this site, and for reasons you may not have considered. Curiosity is a giddy thing, and it is a fundamental part of what draws me here. If you read this site and see only the occasional jerk rather than the experience-driven insights, that is your misfortune. Maybe instagram is your thing. I hear they have a lot of cat pictures.
- mjmsmith 4y agoWhat makes you think the jerks are only occasional?
- froderick 4y agoI've been reading this site fairly regularly since 2010. Not as long as many, but long enough to feel confident saying that though the cast is always changing, this site remains one of my favorite places to 1. discover things I hadn't considered previously 2. reevaluate my past decisions in a way that makes me thoughtful about future ones It is partly the articles, but more the comments (and careful modding). HN stands out as a great place to expand my awareness. There are people here with deep technical experience that care about the outcome of their conversations. The flame-bait and regressive behavior isn't the main thing going on, it is a sideshow. If that ever changes for me, I'm out of here. The article fodder is not as interesting to me as it used to be, but there are gems, and the comments remain engaging. Who knows, perhaps I'm one of the jerks? Perhaps I'm the dreamer that dreams the dream and am therefore the jerk expert? Hard for me to say, but I welcome your opinion.
- chris_wot 4y agoSpeaking as a reconstructed jerk, I have worked hard at not being one but sometimes it slips through the net.
- cmdialog 4y ago
- zaat 4y agoBut do they shave themselves?
- cassianoleal 4y agoGiven you're leaving a criticism on HN, I infer from your own comment you're not worth listening to.
- AnimalMuppet 4y agoNice use of recursion ;-)
- yetanotherloser 4y agorofl
- livinginfear 4y ago> ...not worth listening to anyway... > ...Most of the users of this site... > ...think they're more brilliant... I suppose the above critiques are not directed at yourself?
- stickfigure 4y agoLooks great! Please add an unambiguous timestamp type :-)
- Dylan16807 4y agoIf you get it added to javascript, then it will likely get added to JSON5 or a successor. Otherwise that's out of scope.
- stickfigure 4y agoJavascript has a timestamp type, Date. Of course what you mean is for javascript to have a timestamp literal. Well, the closest equivalent would be: `new Date("2021-12-17T03:24:00")` It's cumbersome, but I would accept it: { mytimestamp: new Date("2021-12-17T03:24:00") }
- secondcoming 4y agoDoes ‘downloads per day’ actually mean anything? It could be someone large company’s CI system building on every commit. I don’t think I’ve ever seen a JSON5 file in the wild. I’ve always wanted comments in JSON, but the other issues highlighted are not things I care about. The ‘be lenient in what you accept’ philosophy is a disaster, just look at HTTP… stricter is better IMO.
- abirch 4y agoIf you had OpenAPI to document the JSON, where would you use comments in the JSON payload?
- NonNefarious 4y agoWhy would you assume that you would? If you did, I guess it would be anywhere that you had a description in the OpenAPI document. But I wouldn't do that.
- snookerdooker 4y agoAlthough I cannot assume, I'd at least hope that a "large company’s CI system" would cache the frequently encountered version(s) of a certain dependency :/
- metadat 4y agoNot a safe assumption. They tend to only invest effort into caching after getting blocked. As a concretr example, this is a common big problem for NPM, and they have to resort to blocking IPs and/or CIDR ranges.
- onion2k 4y agoDoes ‘downloads per day’ actually mean anything? It could be someone large company’s CI system building on every commit. I don't think you understand quite how many 60,000,000 downloads per week is if you think a big company's CI pipeline might account for that.
- dejawu 4y agoI'm kind of appalled that the Hashicorp guy went that far to put someone down for just building something they found useful to themselves. What a great way to discourage someone from expressing themselves creatively. Glad Aseem carried on regardless.
- cmdialog 4y ago
- okanat 4y agoI wouldn't want to work for some company whose founder can be openly toxic against a project that solves an actual problem.
- iasay 4y agoPerhaps he's jealous as half of Hashicorp's portfolio only create more problems than you had originally...
- PoignardAzur 4y agoThis comment seems to be an example of the exact toxic mentality the author was complaining about. Like Hashicorp products or not, the remark seems a bit petty.
- mberning 4y agoHow many years ago was this? I’m sure Mitchell has grown a lot and matured since then. Just like everybody else. He did something a little mean spirited. Maybe even something he regrets now. I think he deserves a little bit of grace.
- lrx 4y agoAn apology is powerful leadership. The resolution I've seen, slinking away as if it never happened, is pure cowardice.
- 4y ago
- pjbk 4y agoWhenever I need to use JSON in my projects I always check if I can use JSON5 instead. It really makes a difference to have a more user friendly format. My only gripe is when I use Python, the official JSON5 module is much, much slower than Python's JSON parser. I frequently end up translating the development JSON5 files to JSON files that go into the final runtime because of this.
- moffkalast 4y agoAs much as the spec for this looks like a list of features that one hardly believes are absent from the original JSON, this just makes things worse as you now have to check which type you're working with, as if there are already not enough places for things to break. https://xkcd.com/927/ https://xkcd.com/927/
- smitty1e 4y agoI'd never heard of JSON5 ahead of this post. As long as we're clear that JSON5 never gets a .json extension, what is the problem?
- 11235813213455 4y agoThe only 2 things I'd like to add in JSON are trailing commas and comments, and this is already supported in most JSON configs (.eslintrc, .babelrc, ..), it's called JSONC I believe
- mikepurvis 4y agoA native set type would be nice too, and the syntax for it is obvious— comma separated values like a list, but enclosed in braces like a dict.
- aaaaaaaaaaab 4y agoA set is just a list with a uniqueness constraint. JSON already has a list type.
- Dylan16807 4y agoTo each their own, but I find mandatory quoted keys a pain in the ass, and once you change those three things you're basically at JSON5.
- musicale 4y agoI kind of wish Apple hadn't deprecated NeXT-style property lists and had instead gone in the direction of GNUstep by trying to improve the classic format.
- ttiurani 4y agoAnother name for this is JWCC. IMO very good argument for this feature set here: https://nigeltao.github.io/blog/2021/json-with-commas-comments.html https://nigeltao.github.io/blog/2021/json-with-commas-commen...
- Dylan16807 4y agoNote that that page forgets to actually make an argument against unquoted keys. The "Why not JSON5, JSONC #1, HJSON or HOCON instead?" answer says it's because of "unquoted strings", then links to a section that only talks about unquoted values. JSON5 doesn't have unquoted values.
- Barrin92 4y agoI don't think writing an article about hackernews comments from two years ago is exactly what I'd call a lesson in ignoring the haters, but this reads a little bit like someone writing an article about the roaring success of null references after their adoption. despite popularity, most of the technical comments in that original thread aren't wrong. 'Popular', 'Easy to adopt' and 'a very bad idea' can be overlapping circles, in particular in the world of javascript and npm
- pledg 4y agoTen years?
- bayindirh 4y agoFrom my experience, the current generation of programmers value convenience beyond everything else, with a great margin. This is not wrong per se, but it calls for much more complex code which handles all the edge cases, and hurts performance at the end of the day. Then, this small performance penalties pile-up and the same developers ask why their code is not working as fast as it should. I don't call for very pedantic formats, and extremely hand-optimized systems. I just wish there was some more awareness of the trade-off they're making and making small inconvenient, but technically lighter trade-offs, these codebases can obtain very dramatic speedups.
- dietrichepp 4y agoI don’t think this is in any way specific to the current generation of programmers. The generation that learned with BASIC or used Smalltalk or Lisp in college is decidedly an older generation at this point. If performance is important, you profile. Optimizing your configuration format for parsing speed is likely a bad decision unless you’ve identified that it’s a problem.
- smoldesu 4y agoPerformance is a relatively minor problem here, complexity being the bigger concern. For example, I really love all-in-one programs like Rust's 'cargo' and Nix's 'nix', but the work that goes into making them work properly is astronomical. On top of that, both of those programs have limited composability and fight for dominance with other interlocking tools like rustc and nix-env, respectively.
- gervwyk 4y agoI enjoy using json5. I solves a real problem imo.. Regarding the criticism, I get the same bad energy when people get a kick out of fixing someone’s grammar, and then do not even comprehend what is being complicated. Well done on the lib and thanks for building something useful! Good writeup also! Think I’m going to give the commit access trick a shot.
- arinlen 4y ago> I enjoy using json5. I solves a real problem imo.. And what problem would that be?
- scient 4y agoSame one that HTML7 solves.
- emptyparadise 4y agoHaving a tolerable experience when forced to hand-write JSON?
- RobertWHurst 4y agoIf you don't know then why are you commenting? Go read the Readme, and stop talking smack about other people's projects when you don't know such basic details.
- codedokode 4y agoHonestly I don't understand why JSON should be human-readable. It is a data serialization format intended to be read by software. Just adding comments and multi-line strings doesn't make it human-readable, it is still too bloated and I don't like writing it manually. If you want a human-readable format, try at least to remove unnecessary quotes, brackets and commas and make it look similar to YAML. JSON is not intended to be used in configs and other user-editable files.
- cgrealy 4y agoBecause it's really handy to be able to run things like rest requests without any tooling more than curl or postman?
- userbinator 4y agoAlso, "human-readable" is somewhat of a relative term. I can read a hexdump of many binary protocols as easily as I can English, and over a billion humans can read a language that seems impenetrable to the other several billion on this planet.
- Jare 4y agoI read and write json manually almost every day. I haven't bothered to insert json5 in our pipelines for various reasons, but I sure wish it was the default. The interesting question I think is, why do you think json is so used in that capacity despite not being meant for it? Why YAML, despite being so widespread, hasn't swept json away for those purposes? (let's for a moment ignore that YAML can go REALLY nuts, and think only of the simplest version of it)
- LtWorf 4y ago> let's for a moment ignore that YAML can go REALLY nuts, and think only of the simplest version of it But we can't ignore it… we have to validate and make sure it isn't going too nuts. And we will probably fail at that.
- Falkon1313 4y agoI used to think YAML would be great for that sort of thing. Now, having dealt with some large YAML files, I understand at least a couple of reasons why people don't like it for that. Things that are invisible when visually looking at a file, and not really detectable by IDEs or linters or anything (because they would have to assume your intent). In a small file, semantic indentation is beautiful. In a large file where you have to scroll and scroll to find out where you are, it's a pain. And perhaps importantly - can't be autoformatted. Your IDE doesn't know what indentation level you intended, and without braces/brackets to tell it, it can't detect errors. There's parsing automagic wackiness if you're not careful (the famous example: country abbreviation NO for Norway becomes FALSE). The nice feature of references is almost never actually used in practice. An incorrect or circular reference can look fine but badly break things. Yaml typing is application (and version) dependent so not really useful. There's more, but basically JSON, though simpler and uglier, prevents all of those. You can, and pretty much have to, use an alternative 'safe YAML' parser, but even that doesn't solve some of the problems.
- wdb 4y agoI really like json5’s comments support, especially when json is used for configuration files so you can explain specific confit without needing to do it in a separate file
- TrianguloY 4y agoJson comments is something I always wanted, for json files with data that you need. I even use regexp to remove them in some cases (where I know it won't conflict with the strings themselves). Didn't knew about this json5 thing but I'll try to use it instead.
- JoshuaEN 4y agoIf you just want comments (and trailing commas), there is also this: https://www.npmjs.com/package/jsonc-parser https://www.npmjs.com/package/jsonc-parser
- furyofantares 4y agoNon-constructive criticism is extremely easy to produce and can make the author of it feel smart for a second. Doing it in a place where folks share their creative works is like shooting fish in a barrel. There may be a tiny bit of signal in such comments but it's mostly just noise. I try to just ignore any comment that looks like the commenter just wrote whatever came to their mind, they're gonna forget about it in 10 seconds too when they're off to the next thing to react to.
- vlunkr 4y agoMany of those original comments were pretty spot on though. Maybe the constructive criticism you need sometimes is “don’t do this” JSON is useful partially because it’s easy to parse, so parsers already exist in every language. Extending the syntax is undoing all the communal work, and encroaching on grounds that YAML and other languages already cover.
- bobthepanda 4y agoThis seems like making a mountain out of a molehill. > Extending the syntax is undoing all the communal work JSON5 takes stuff from ES5.1 and adds it to JSON, and ES5 is backwards-compatible with older JS. This means it's fairly trivial to convert JSON5 to JSON (literally 13 lines: https://gist.github.com/iddan/3d34b12f6b22c30a8a07c149b3175e2f https://gist.github.com/iddan/3d34b12f6b22c30a8a07c149b3175e...). And ES5.1 itself was the product of communal work. > encroaching on grounds that YAML and other languages already cover. I don't know that we should really start dividing features into nice little boxes so no one steps on each other's toes. Trying different solutions for the same problem can eventually bring us more optimal solutions than if we just sat around twiddling our thumbs because 'it's been done'. It's not like there's an army knocking on your door going "switch to JSON5 or we'll kick your teeth in." People can stick with what they want to do on the merits, but I don't see that as a reason to shut down others' work.
- jhardy54 4y ago> This means it's fairly trivial to convert JSON5 to JSON (literally 13 lines: https://gist.github.com/iddan/3d34b12f6b22c30a8a07c149b3175e2f https://gist.github.com/iddan/3d34b12f6b22c30a8a07c149b3175e...). Did you paste the correct link? This just plumbs together an existing JSON 5 parser with a JSON 4 serializer. How many lines does this take without importing a library the solves this for you?
- didgetmaster 4y agoI can really relate to this. I posted something earlier this year about how a number of file system problems are directly related to an archaic architecture that was designed when hard drive capacities were measure in MBs. I offered a possible solution in a hobby project that I have been working on for years. https://news.ycombinator.com/item?id=30449263 https://news.ycombinator.com/item?id=30449263 While there were some really good comments, the vast majority were very negative and critical. (BTW: the comments on HN were much more civil than on Slashdot where the story also got picked up) Still, I didn't ignore the criticism but tried to learn from it and there were some encouraging comments mixed in as well.
- SahAssar 4y agoI read through most of those comments and while a lot of them are critical or negative I would still say most of them are "good" as in that they are constructive and give feedback on the idea or it's execution. When you say "While there were some really good comments, the vast majority were very negative and critical" it sounds like you think that negative or critical comments cannot be good.
- didgetmaster 4y agoI took another look at the HN comments and I think you are right, there were a lot more constructive comments there. I guess I just remembered the toxic comments on Slashdot a lot more and mixed the two in my memory.
- leaflets2 4y ago> I just remembered the toxic comments We tend to pay more attention to the negative and dangerous -- a survival thing, right (from when we were hunters and gatherers)
- midoridensha 4y ago>(BTW: the comments on HN were much more civil than on Slashdot where the story also got picked up) Slashdot stopped being a worthwhile place to frequent at least 10 years ago. It's devolved into an utter cesspool, since all the quality people fled for greener pastures ages ago. I recommend ignoring its existence altogether at this point, along with any comments from that site.
- thrown_22 4y agoI still don't get what the point of json is. If you want to dump raw JS data structures as text just do. You don't need a spec or special tools. If you want human readable XML just use s-expressions. Something that's so easy to parse you can roll your own in an afternoon. Json is trying to square the circle of "I want things to be easy" but also "I want to not shoot myself in the foot", goals which are mutually exclusive. Every new version of json is just gods way of teaching people how XML got to be the mess it is.
- t0astbread 4y agoIf I wanted to dump raw JS data structures as text the most straightforward way I can think of is `JSON.stringify` and `JSON.parse`. No need to roll your own S-expression parser.
- thrown_22 4y agoconsole.log(a) eval(a)
- TylerE 4y agoShockingly about 98% of the population doesn't find massive mounds of nested parens especially readable.
- stavros 4y agoRegardless of JSON5, I realized it's just not constructive to tell someone why something they made will fail. It would be great if you could tell them how to prevent failure, but just portenting it serves nothing.
- throwaway0x7E6 4y agothe general attitude of the critics is correct. the name you chose has implications that are not true - JSON5 has nothing to do with JSON and you have nothing to do with the people who came up with JSON. have you named it something else, you'd receive far less (if any) negative comments.
- deleted 4y ago[deleted]
- jimrandomh 4y agoHere's the old (2012) HN thread with the haters in it: https://news.ycombinator.com/item?id=4031699 https://news.ycombinator.com/item?id=4031699 . Happy to see an old (positive) comment of my own that I had forgotten about, which I think sums the whole thing up quite well. It still applies, so I'll repost it here: You know that something has gone very deeply wrong somewhere when people oppose your project because they are ideologically opposed to comments. In my own experience, finding out that many JSON parsers reject comments was a real WTF moment, and a deal breaker for my config-file application, so I ended up using JSON-plus-comments for it instead of JSON. At the same time, lack of support for trailing commas and unquoted member names have been a minor but persistent thorn in my side for no good reason. The justification for not having comments in JSON is that in the great disaster that was XML, some projects would parse the comments and take them as semantically significant. However, the real problem there was that parser libraries would expose the comments, and that some generators would put important information only in comments. But I think that these mistakes are unlikely to be repeated, and that the proposed alternative - moving all comments into the markup, or eliminating them entirely - is just obviously worse. One of the things that ruined the XML ecosystem was a persistent belief that XML was to be read and written by machines, combined with a reality in which it was mostly used for human-written config files, leading to a tolerance for awful syntax (like prefixing every single attribute with a namespace, and the ridiculous CDATA notation). I'm seeing the same thing with JSON: A significant fraction of its use is for human-written and human-read config files (which often desperately need comments) and people are pretending it's strictly a data interchange format that shouldn't be used for that. It is sometimes said that JSON was discovered, rather than invented - that the syntax was already out there. So it is with JSON5: There is nothing new in this, it is simply return to JavaScript Object Notation and bringing in the rest of what Javascript has. So, all you pooh-poohing ideologists: please seriously rethink whether disallowing comments, trailing commas, and quoteless member names is actually a good idea. Consider this in light of the fact that JSON is widely used, today, as a config-file language, and that {"--":"This is a comment"} is ridiculous enough that no one does it in practice, can't be inserted on any line, and invites consumers of your data to parse the comments.
- deleted 4y ago[deleted]
- hsbauauvhabzb 4y agoI integrated json5 into a project I regularly use. JSON5 saved a significant amount of ongoing debugging. I appreciate the efforts that went into the project. Thank you.
- ryscheng 4y agoOn the other side of this, it's fascinating how often people fall susceptible to arguing why something should or shouldn't exist for someone else, rather than just making a limited statement about utility for themselves. Something to stay cognizant of, this article is a good lesson on empathy!
- LtWorf 4y agoNot everything is about yourself. And once everyone is using some terrible format you won't be able to avoid it anyway.
- fefe23 4y agoLet me give you a data point from a neutral perspective (I have never heard of you or JSON5). These were not haters. They in fact went our of their way to give arguments supporting their verdict, and in some cases even constructive suggestions like "make that a preprocessor instead". Your piece does not make you look like the smartest guy in the room, vindicated by success and adoring fans. It makes you look like someone who confuses internet fame points with something that actually means something. Like a sore loser who needed to convince themselves that they really are the smartest person in the room. The internet is a trap. No matter how bad your idea is, you will always find people who think it's great. Just look how many people Alex Jones found who agreed with his Sandy Hook ideas. Don't go looking for fans. Go looking for people who disagree, as they will help you improve your skills and grow as a person. If you were actually as good as you apparently think you are, you wouldn't be wasting time writing text like this. You wouldn't need to. Your work would speak for itself. I don't remember Mozart or Einstein lament about their haters.
- deleted 4y ago[deleted]
- LtWorf 4y agoI wrote a python library. Someone online told me another library (released after mine) was doing the same thing. Turns out other library has very obvious bugs, is 20x times slower, but it has 8x more downloads. Yep downloads are not a metric of quality.
- Tainnor 4y ago> I don't remember Mozart or Einstein lament about their haters. Can't say for sure about Mozart, although I really would not put it past him to do so. But here's Beethoven doing the same thing: https://quotepark.com/quotes/2122354-ludwig-van-beethoven-o-you-miserable-fool-what-i-shit-is-better-than-a/ https://quotepark.com/quotes/2122354-ludwig-van-beethoven-o-...
- renewiltord 4y agoPhew, when I read these posts, I often wonder if I said something dumb in the past and I think I can easily be proud of my comments there, though I missed the JSON5 thing[0]. Fortunately, the thing that keeps me from saying dumb shit about other peoples' tech is: * my belief that people who execute on some project are inherently superior - they made a thing to solve a problem! Automatically superior to people who didn't make a thing * the Blub Paradox http://paulgraham.com/avg.html http://paulgraham.com/avg.html I can only judge projects accurately where I am operating at a higher-level of thought. If I don't get the need, then I am probably not operating at a higher-level than the author. I prefer to be able to have sufficient Theory of Mind thinking that I can inhabit the author's mind to see why they need something, make the best case for it, and then reject/accept it if I have to. There are many places where I can't. The most trivial example which everyone grasped before I got there is GraphQL as an API specification and IDL, which I only recently really grokked. In any case, I had a figment of the idea that you talk about which is the "people who won't be your users". Thanks for citing the thought around that. Congrats and good luck! 0: https://hn.algolia.com/?dateRange=all&page=0&prefix=true&query=json5%20renewilt&sort=byPopularity&type=comment https://hn.algolia.com/?dateRange=all&page=0&prefix=true&que...
- sacrosancty 4y agoPerhaps the fact that it's popular is exactly what those nay-sayers were worried about. They didn't want a more fragmented world of incompatible standards.
- wruza 4y agoSome appealed to unrealistic things though, like “all decent text editors should help to make json typing/formatting bearable instead”. Yeah, that totally worked before and will work this time too. We’d all do much better if our standard formats weren’t such an annoyance to work with in the name of something that computers wouldn’t even notice eventually. If there is a void inside a busy place, it will be filled regardless. With that in mind, think what would happen if something much less adequate filled that void. They didn’t want world which couldn’t care less about how anyone wanted it to be. But that’s what we can only have.
- wildwildtest 4y agoI think the real lesson is that popularity is a poor way of understanding whether something is actually useful or good, it can indicate those qualities but meaningless without also applying our reasoning faculties too. The author appears to remain oblivious to any of the very good reasons why people don’t like alternative json formats and incapable of incorporating that into their understanding of people’s reaction. Citing market mechanics as a justification of “popularity = value” is blowing past the many examples of where free markets produce terrible approximations of value. Also, I think it’s very poor character to say on one hand that people’s reaction doesn’t bother them and dedicate a third to a half of the article to Mitchell’s criticism specifically. I think Mitchell’s criticism is completely reasonable (I remember this as an era of “solving json” through multiple alternative formats) and drawing attention to what seems in retrospect as a mean-spirited act is actually quite a cynical attempt to strip the context of it and deliberately cast Mitchell in a poor light. Mitchell’s intention is very clearly a technically minded one to nudge people away from trying to massage long term, durable standards in often trivial, subjective ways with an end goal that can only result in format thrashing that doesn’t ever address anything substantial.
- mikkergp 4y agoExcept Mitchell explicitly called the author out in his satire and the author was right that Mitchell thought in retrospect it was a mistake to do so. Why is it in poor character if he’s expressing a view Mitchell agrees with. Additionally in terms of the criticism, I observe the inverse phenomena to what you describe. You say that popularity isn’t a good indicator of goodness, but I think the inverse is goodness isn’t an indicator of eventual popularity. Some very elegant solutions just aren’t flexible enough for the real world. It is short sighted to try to argue some objective definition of badness because it doesn’t solve a problem you have or doesn’t fit your version of what a product like that should be. Sometimes in the absence of perfection people just have to get work done and want tools that make that easier.
- wildwildtest 4y ago> Except … I think that’s the sleight of hand occurring right, it’s reasonable to say he might mot have linked to it, but the purpose of the repo was not to shame the author. It might be my own predilection, but it strikes me as dishonest to say “I didn’t mind this” and then imply the opposite. > Additionally … Right, me too, they both occur. I don’t think I actually specified an argument as to why json5 is bad or even argued that it was. My comment is mainly about the article itself. This whole paragraph reads as an argument to not use json5 given that it is very much trying to perfect the imperfect json, which most people just get on with.
- justinlloyd 4y agoIn videogames, "If there are enemies ahead of you, then you are going the right now." I have long held the belief that if the audience of Reddit or Twitter or Slashdot or Hackernews universally hates something with such vehemance that you doubt your own thoughts then you are probably doing the right thing. In the words of Casey Neistat, in his video "Do what you can't." - "To the haters, the doubters, my 7th grade vice principal, to everyoneone who has ever anyone with a dream they can't..."
- remram 4y agoThat's a terrible outlook. You are saying that all negative feedback should be ignored by everybody and treated as a positive sign. This is insane.
- justinlloyd 4y agoNowhere, not once, did I say that all negative feedback should be ignored. I specifically stated "I have long held the belief that if the audience of Reddit or Twitter or Slashdot or Hackernews universally hates something with such vehemance that you doubt your own thoughts then you are probably doing the right thing." This is not "all negative feedback" or "that it should be ignored by everybody" or "treated as a positive sign" and it is disingenuous of you to imply otherwise or to conflate it as such. I'd like to introduce you to a video between a psychologist and someone with an agenda: "So what you're saying is..." No, that's not what I am saying at all. I cannot decide if you have poor reading comprehension or want to twist someone's words. Perhaps both. I'm done with this discussion with you because I'm not going to engage with someone who suffers from the former or wants to engage in the latter.
- leaflets2 4y agoA different but similar saying could be: "If you've found something that arouses interest and debate, you might be on to something" And critique, or a gathering of enemies, is interest in something (interest in the stuff the enemies in the game are guarding)
- 4y ago
- AndriyKunitsyn 4y agoI'm really puzzled by "JSON is for machines, not for humans" types of comments here. FFS, JSON has whitespaces, that alone should answer who it was made for. And making human-readable formats more human-readable is a good thing. JSON5 is awesome. If the performance of your module suffers from parsing its inputs, you are doing some Really Terrible Thing with your inputs. And if the nature of the task really requires you to parse data quickly and on a big scale, it would be better to ditch JSON altogether and switch to a binary format like protobuf instead.
- deleted 4y ago[deleted]
- yawnxyz 4y agoI love JSON5! My only gripe with it is that I have no idea what the "5" means, and I don't think it's documented / alluded to anywhere...
- cbarrick 4y agoThe 5 is a reference to ES5
- livinginfear 4y agoI don't think ignore the haters is sage advice in this context. What was directed at this project in the original HN thread was not hate, it was criticism. These are very different things. People were not abusing the author. Some of the original commenters had very salient critiques, and questions. "Ignore the haters" reads like: "I ignored all criticism of my idea, and some other people like it anyway.". There's already so many terrible technologies in the web programming domain that have plowed onwards in the face of so much criticism, and now we're stuck with them. Part of being a good programmer is being humble, and accepting that you might not have all the answers, the best ideas, or see the bigger picture.
- dietrichepp 4y agoThe criticism highlighted in the article looks more like hate than criticism, to me.
- smrtinsert 4y agoI remember the original thread and agreeing about the comments addition. I still think it's a poor addition. That said the meanness is disappointing. Congrats to the author for persevering.
- Dylan16807 4y ago"Horrible. There's a reason JSON is homoiconic with valid javascript." is a weird comment to read about something that takes JSON closer to javascript.
- jaimex2 4y agoThis is the first I've heard of JSON5. I can't say my reaction is any different today. Keep it simple.
- keithalewis 4y agoGlad to see basic common sense winning out. Crockford was too strident about defending his spec. These are minimal changes that sensible developers find useful in their daily work.
- beej71 4y agoI'll take any feedback. If someone tells me I'm dumb and have it wrong, I thank them and fix it. Now they can't complain about it, I learned something, and someone spent their time giving me free advice. But if they don't convince me I'm wrong, then I ignore them. :)
- leaflets2 4y ago> But if they don't convince me I'm wrong, then I ignore them What if, though, they convince others that you're wrong -- so no one wants to use your software? (although it would have been helpful to many)
- beej71 4y ago(Sorry for the late reply.) I can post my counterarguments and then the other folks can decide. If the argument is compelling and cogent, people listen. But I know I'll never convince everyone to like my stuff. The goal is to make a quality, useful product while listening to good suggestions for improvement and not letting people get you down.
- leaflets2 4y ago> If the argument is compelling and cogent, people listen. Yes, ... Maybe ... I hope software people do; maybe they pay a bit more attention to logic and reason. I'm otherwise reading the book "Influence, New and Expanded: The Psychology of Persuasion", and I no longer have such high expectations :-( > not letting people get you down. Good point :-) (Thanks for the reply)
- nojvek 4y agoJSON5 isn’t a crazy language. Just used some productions from ECMAScript spec that is already part of JS. Anyone familiar with JS should pick up JSON5 quite easily. I believe VSCode uses json5 with .json extension for a whole bunch of their configs. It would be a slower parser than JSON though.