4 ms·
There’s something about JavaScript and the length of files, grouping of related lines, and usage of functions that can make it immediately obvious that the qual
by 9wzYQbTYsAIc 7y ago
There’s something about JavaScript and the length of files, grouping of related lines, and usage of functions that can make it immediately obvious that the quality is either atrocious or decent.
I suppose that that extends in part to any C-style language, but the relative looseness of JavaScript really makes it stand out to me, for some reason.
- jka 7y agoNice :) It's a principle of pattern recognition[1] regardless of language, I suppose. It just takes time to learn and internalize the patterns to look for -- and perhaps some languages and syntax highlighters are better than others at exposing those patterns to the reader. [1] - https://en.wikipedia.org/wiki/Pattern_recognition_%28psychology%29 https://en.wikipedia.org/wiki/Pattern_recognition_%28psychol...
- 9wzYQbTYsAIc 7y agoTrue, check this out if you’ve not heard of it before. It’s is a great springboard into the topic of perception: https://en.wikipedia.org/wiki/Gestalt_psychology https://en.wikipedia.org/wiki/Gestalt_psychology
- noema 7y agoTo this I would add a couple of classic mid century studies on perception: Arnheim's "Art and Visual Perception" (which imo should be mandatory for any UI designer), and Merleau-ponty's "Phenomenology of Perception" (this one requires some extensive background reading, but it's well worth the effort)
- searchableguy 7y agoI don't understand why js psychologically force me to write smaller files. Whenever I write in any other language, I feel totally fine with 1000+ LOC in single file but when it's js, the zeitgeist force me to put them into bunch of folders exporting from an index.ts I can't put my fingers on it.
- johnchristopher 7y agoMaybe you want to have the feeling to be in control ? Smaller files, each having one well defined usage, nicely ordered in structured folders, gives me the feeling I understand what's going on. Maybe JS projects feels less solid or grounded sometimes ?
- krebs_liebhaber 7y agoI feel queasy when I see a 1000-line file in any language, but JS in particular is just... yikes. I guess it's because the language has a reputation for being inconsistent (whether that's deserved is another thing entirely), so the less you have to reason about, the better.