3 ms·
Non-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 creat
by furyofantares 4y ago
Non-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?
- bobthepanda 4y agoJSON5 parse constructs a Javascript object, which can in turn be serialized by JSON 4 into valid plain JSON string. That's not an invalid way of converting the two objects. JSON.stringify is part of the standard JS spec: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe... JSON5.parse() is part of JSON5's API: https://json5.org/#json5parse https://json5.org/#json5parse So any project that includes both standard JS and JSON5 could literally copy and paste this code. You're still importing JSON5, but you would presumably have to do that anyways to use JSON5.
- MauranKilom 4y ago> So any project that includes both standard JS and JSON5 could literally copy and paste this code is not a convincing reply to > so parsers already exist in every language
- Falkon1313 4y agoPersonally, I like some of the ideas of JSON5, but it isn't compatible with JSON as implemented. Altering existing systems to use it isn't as trivial as you imply. And requires taking on new dependencies. You'd have to rewrite anything using json_encode() and json_decode() in PHP, or the equivalent standard functions/methods in Python, C#, etc. And also take on another dependency. And maybe lose performance. And then you sometimes may have to know whether you're dealing with JSON or JSON5, and what the program on the other end of the line produces or expects and can handle. For new greenfield projects it might be worthwhile. But most of the world runs on legacy code and many prefer to stick to the standards and minimize dependencies. So it's not that simple. That doesn't mean it's bad though. Like anything else in software, it's a trade-off.
- leaflets2 4y ago> can make the author of it feel smart for a second Since this behavior is so common, apparently it works, evolutionary: It makes others think your are smart, for a long while And not much effort required, on your part. So, a great opportunity? And the more popular the project you start bashing is, the smarter you'll seem? Corollary: If one builds something great, one will get dissed by some.