by jim-jim-jim · 7y ago · 0 comments
I also think that anything js-adjacent has a real culture problem. Trying to dredge an answer out of a Medium tutorial written in a cloying tone and interspersed with pointless gifs can be such a groan enducing experience. I'm hoping that the community will mature alongside its technology.
Manpages and documentation are written to be references. Blog posts are written to be tutorials. They have different affordances, and as a result it is very hard to learn how to use something purely from a reference, and very different to solve a problem purely from a tutorial.
That’s why really decent reference sites have both step by-step tutorials AND references designed to answer questions quickly and to be easily searchable.
If there is an opportunity here, it is for search to understand the difference and know how to present the two kinds of results differently.
That way, if you question is, “How does this thing work?” You should get tutorials. If your question is much more specific, like “what parameters does this take?” You should get a reference.
Or something hand-wave-y along those lines.
For example, the other day someone asked on stackoverflow why a particular Java class to calculate a difference between two dates was returning a weird result when they asked for the difference in days. Turns out, the class would calculate the difference in years AND months AND days, so if you asked for the difference between June 23 2018 and June 23 2019, the getDays method would return 0.
While this is something you would find in a tutorial on how to calculate a difference between dates in Java, it's much more expedited to just go and read the reference. Works wonders when you get inconsistent results in C for example, since you're probably invoking undefined behavior which is documented in the standard (i.e., the reference).
As a sort of counterpoint for this particular case, the documentation for that class didn't make how the class was meant to be used clear at all. But in the general case I think it applies.
The other problem is that you're not really fighting JS or CSS or HTML per se, but a browser implementation of interpreters for that. And you don't really have a say in the matter, because you're not picking what browsers are using your webapp, your users are. This is only really solvable using a combination of MDN, Stack Overflow, and Google-fu.
Either these are very rare, or there are hard to google because they are drowned out by the many tutorials.
When you follow a tutorial, you are shown a very specific way of doing things (which often isn't up to date, with no indication that in the meantime this way has been replaced by another way).
And while that's very helpful for a beginner, it isn't as helpful for an experienced programmer, especially if he or she is having a problem that needs a slightly different way of doing things, and the missing information is just "instead of X, you can also do Y here".
And references don't answer these questions, unless you work through them from top to bottom (which usually takes more time than you have).
When I work with most stuff that isn't web dev, life is good. I can figure most stuff out painlessly. It's mostly feels like working on a space that has been designed and documented by someone sane.
When I'm forced to do Web dev type stuff... I want to jump off the roof. It always makes me question my life choices that led to me being exposed to js. I hate it, it's a logically incoherent disaster that feels like its been deigned by people who are all just winging it and sorely lacking a good CS degree. It all just feels immature and feels like it's a field trying to develop methadologies while ignoring lessons of the past and as a result making mistakes they shouldn't be.
Once you get into this npm / node nonsense it feels like proper wild west madness.
I'm sure it will mature some day. I'll probably be retired by then though. Then again maybe the entire eco system is doomed to a future of just constant nonsensical churn and the solution is just therapy or install nets on the tall buildings to catch devs, who after spending another day hating js, decide to junp off the roof!
Another problem is I don't see many Web developers wanting to learn when they encounter something they don't understand, instead they just want some code they can copy and paste that had the illusion of solving their problem. Understanding be damned. Or even better a library, and hey if it has a million dependencies... Well.. That's life right?
Someone is speaking the truth here. But we (as a web dev I'll try to speak for us) are learning: React and Vue (and all the other great libraries) use optimized vdoms, React teaches functional programming paradigms with immutable data structures (redux) and we've already learnt from Ember what components we'll need in a project.
Most people will simply follow blindly. After the base stops moving (breaking changes in the APIs - Vue is currently doing the last big ones), we will write the best practices. Every half-decently educated developer already understands that those ideas are not new. They are the same ones they've already had in the 60s. They will try to do it better - maybe they really are more clever, right? - but after the third or fourth try they'll understand that their own half-baked solution doesn't stand a chance. And then they will realize that life is too short to lose some data because your file-based DB implementation isn't ACID.
It's especially true when you lower the bar to entry. There's lots of CRUD because anybody can make something. It also means there are lots of things.
If you want well-documented stuff, vote for it by not using things that are poorly documented. Or figure it out and write the documentation. That's how open source works (or doesn't work), and JS/Webdev is not unique in this regard.
Microcomputers were poorly documented way back in the 70s. I'll be there were people complaining how shoddy they were on that basis, but that low barrier to entry led directly to us having this discussion on Hacker News today.
Tone is a different matter, tutorials sure can be more lighthearted. But I'd still take a dry tutorial instead of forced, stillborn humor any day. (I'm not sure if the latter kind is all that common in the wild, could be an illusion of frequency on my part).
It’s a perfectly valid choice to write essays that are hyper-focused on just teaching the facts as efficiently as possible, but that isn’t some kind of universal rule that must be applied to all essays.
I personally don’t care for the popular “American Folksy” style of essay that is heavy on the author’s journey to learn the thing it purports to teach, but I wouldn’t dictate that nobody should write in that style.
There are no gatekeepers to writing words, just as there are no gatekeepers to writing code. That has its benefits, aand its hazards.
Of course, just like anyone's free to say "it's a generic 4:4 I–V–vi–IV pop song, nothing to write home about" or "it's yet another ISO standard blogpost, don't bother clicking through the popup". Though I think a better equivalent of a meme-laden blogpost would be a sea-shanty with changing time signatures and atonal riffs with a rabid scene kid at the vocals - kind of bizzare, kind of crass, fully useless for pulling a rope on a galleon.
>It’s a perfectly valid choice to write essays that are hyper-focused on just teaching the facts as efficiently as possible, but that isn’t some kind of universal rule that must be applied to all essays.
I wasn't arguing that every blogpost should be hyper-focused, just that it would be kind of nice if more people took the route of "uncreative but solid" rather than "trying to create an illusion of creativity with randomness".
Tag documents into categories (using ML diceroll, up to one category per document), with a strong bias towards "none" when in doubt. When a search term's results include some categories more frequently than the global average, offer them as filters.
Would its utility survive the resulting wave of SEO innovations?
I don't really get this response. First there's the notion that "webdev" is the discipline where information is so fractured that you need to go googling around to figure out how to do everything. All the other disciplines have a magic thing called a man page that just gives you the answers. This is obviously not true, right?
The second thing is the idea that a man page for any one component, or even a set of components, could possibly contain enough information to allow you to build a complex system without consulting the experience of peers, colleagues and past practitioners, which is at least what we intend to do when we search google.
It is true to some extent. The less dependencies you have the less you need Google. Have thousands of dependencies in node? You will likely google their different error messages a lot. Write low level C libraries where not having dependencies is a key feature? Then Google wont help you much at all, the few times I try I almost never find anything useful for my work.
So the thing about web dev is that you automatically have all browsers as dependencies, not to mention all the libraries, frameworks and api's people are using in modern webdev workflows. Most other fields tend to have much simpler dependencies than that.
I love how this is a unit of measure now. "I have never met anyone with an iphone, so...".
Piping six man pages through grep to find what I’m looking for is simply not as fast as Googling an error message.
I think there’s also a sort of cultural difference between languages and tools frequented by newer and older programmers: more experienced people look for documentation and then get working on their project, whereas less experienced programmers look for tutorials and very specific “soft” documentation.
Transitioning from modifying tutorials (the type-in-the-code-in-the-magazine of the 21st century) to glancing at the documentation is probably the surest sign of maturity. Still, you can get a ton done by copypasta.
This might have to do with learning to code with or without the Internet, I’m not sure. I’m personally very envious of people who can take a look at the docs and just get chopping without the assistance of the GIF-covered Medium posts.
This says more about the man pages for grub2 (and grub2 itself, to be honest) EDIT: than about manpages /EDIT.
Compare them with the man pages for grub1. There's a sea of difference.
If you really want to be blown away by a manpage, look for the one for mplayer, which is difficult to find information in for different reasons, i.e., lots of options and lots of options and flags that depend on other flags and options.
In the BSDs, self-contained, complete, and correct documentation is a cultural value. Not one that’s always achieved, but a value nonetheless. Information missing from the man pages is a reportable bug.
And if the man page doesn’t document something, its code is right there in /usr/src for you to dig into.
Not so with webdev. That said, the source code is there for all of us to read. I'm a frontend developer and spend more time looking at source code when I need to figure out an issue than digging through Medium posts. Particularly when something is behaving in an unexpected manner.
I'd urge everyone who hates webdev to try this approach the next time they struggle with an issue. JavaScript, for all its sins, is fairly easy to read. And once you've understood the ~30 most common gotchas in JS, reading the source is highly beneficial (and here's a good intro to those gotchas, including an accompanying video: https://github.com/denysdovhan/wtfjs)
Or better yet, work in one of the statically-typed compile-to-JS languages such as Typescript, ReasonML, Elm, ScalaJS, or Purescript and worry about those gotchas much less (and only when wrapping external libraries).
>Options to GNU tar can be given in three different styles. In traditional style, the first argument is a cluster of option letters and all subsequent arguments supply arguments to those options that require them. The arguments are read in the same order as the option letters. Any command line words that remain after all options has been processed are treated as non-optional arguments: file or archive member names. For example, the c option requires creating the archive, the v option requests the verbose operation, and the f option takes an argument that sets the name of the archive to operate upon. The following command, written in the traditional style, instructs tar to store all files from the directory /etc into the archive file etc.tar verbosely listing the files being archived:
Scanning through the manpage a fair way down and I can't see the one bit info that covers almost all of my use cases for tar.
And for anything more complex than a tiny cli tool the manpage is far too large to use usefully.
but what evs. sometimes the man page is the thing, sometimes not.
There's also a web interface, for tar that'd be: https://tldr.ostera.io/tar
Anyone could divine some reasons for why javascript / “web dev” is so different but I’m seeing shades of the same thing mixed with personal biases towards trade offs and design decisions.
Recently I've been developing in Flutter/Dart, and it's so enjoyable. The Dart language is an improvement on Java, the Flutter documentation and online support is great, apps look and behave the same on different devices, the API and underlying code is well designed. Plus the tooling and IDE integration is first-class.
Perhaps this is because it is just so much less of a hassle to do so in a world with things like NPM.
You don't have to search the internet for web dev any more than you have to do so for any other dev job.
Google: just type in a quick description of your issue and get a stackoverflow post with an answer as the first result.
I don't get how anyone could prefer the man page.
If a library vendor provides good docs on their website, that’s just as good as man pages, but in my experience they usually don’t.
There is a staggering amount of misinformation or non-existent information on Stack Overflow. For one simple example: try to figure out how to use the GPS on iPhone. It’s simply impossible. 99% of people on SO think “GPS” is synonymous with “Location APIs” in general. Of the 1% of people who understand the several different data sources used by CoreLocation, nobody can tell you which accuracy settings will cause it to use GPS specifically. If you bother asking, you’ll get a bunch of “middle-brow dismissals” asking why you want to know such a thing, telling you to just use whatever accuracy setting you semantically need, smugly claiming you’re guilty of posing an A-B question, and so on. This is the type of dead simple basic information I would have expected to be present in Apple’s documentation, instead of having to crowdsource it from internet trolls.
Technology moves on and those early answers are simply no good. Recently I decided to learn a few things from first principles - reading the specs. If I then try to put a half decent answer on SO then it will be answer 97, 3563 upvotes behind the 'right answer'.
New person who comes along isn't going to get to my detailed answer on page 5, the one that points out how technology has moved on and why the winning answers are not what you needed. They just need to deliver the deliverables and the first answer will suffice. They will take it and add another plus to the upvotes.
You can't win, the odds are stacked in favour of the mediocre. This wasn't always the way with Stack Overflow, in fact it replaced forums where the same problem existed but only to stall the nonsense for a few years, we are back to peak nonsense again.
I think time is ripe for Stack Overflow to be usurped, nothing against the site which I have so loved over the years, but even mySpace had to be replaced by Facebook.
Maybe some kind of super downvote for outdated questions that is strictly moderated so it isn't abused.
I think manpages are a popular thing to worship here for nerd points but people don't use them nearly as much as they say they do because nobody actually wants to read a manual when they are trying to Get Things Done. Also, some things are just incredibly hard to figure out, like ffmpeg arguments.
Check out http://bropages.org/
Because manpages are from a time when reading the manual was expected behavior, searching for a quick incantation more often than not results in learned helplessness because you don't actually learn anything, just the specific spell for the specific situation.
I'm as guilty as anyone of trying to solve the immediate problem with a magic spell at times, but bropages embrace this willful ignorance.
Btw if you find the MDN search unsatisfactory (as I do) try mdn.io/search term. It's just a proxy for site:developer.mozilla.org search term + I'm Feeling Lucky.
The problem with a reference is that a lot of times browsers do quirky things and things that are essentially browser-specific bugs aren’t documented in a reference.
Which technology? Web development frameworks seem to have a half-life of about 12 months. 'Mature' and 'obsolete' are near synonymous.
Initial realeases of the most popular JS-frameworks:
Angular – 2010
React – 2013
Vue – 2014
(I'm aware that Polymer insists it isn't a 'framework'. But it is. If their breaking changes cause incompatibilities between components using different Polymer versions, that's what I call a 'framework'.)
Honestly, a lot of javascript criticism I see nowadays is a little outdated.
Still looks true to me. I gave the example of Polymer in my other comment.
All that and emojii's sprinkled everywhere like cat vomit.
and I hate videos cause usually skimming through text you can get to the part you want to read quickly but with videos you need to go through it