5 ms·
Google will also happily surface a stackoverflow article from 2010 about how to solve a js problem... frustrating the top 3 answers will be with jquery, when it
by tholman 7y ago
Google will also happily surface a stackoverflow article from 2010 about how to solve a js problem... frustrating the top 3 answers will be with jquery, when its not the approach someone would take in the last 5 years.
Definitely frustrating, but also showing some need to retire specific pieces of the past away from the top recommendations.
- jquery_noob 7y agoThere are more links to old articles from high quality pages, pagerank algorithm favors those as they are higher quality. Jquery still works and was in use for so long that all people who maintain older sites are still linking to those articles. Eventually as the jquery sites are retired or rewritten pagerank will surface non jquery related articles.
- sorryforthethro 7y agoI feel this too, the "Tools -> Results within the Last Year" (&tbs=qdr:y) is necessary for searching programming issues these days.
- Theodores 7y agoYou have hit on a major problem there. Stack Overflow was once the fount of all useful genius grade knowledge, but times change and some of the top answers are plain wrong. Take for example the 'how do I centre a div' type of question. You will get to find an answer with thousands of up-votes that will be some horrendous margin hack type of thing where you set the width of the content and have some counter intuitive CSS. In 2019 (or even 2017) the answer isn't the same, you do 'display: grid' and use justify/align: center depending on axis. The code makes sense it is not a hack. Actually you also get rid of the div as the wrapper is not needed if using CSS grid. Now, if you try to put that as an updated answer you find there are already 95 wrong answers there for 'how do I center a div' and that the question is 'protected' so you need some decent XP to be able to add an answer anyway. The out-dated answer meanwhile continues to get more up-votes so anyone new to HTML and wanting to perform the simple task of centering their content just learns how to do it wrongly. And it is then hard for them to unlearn the hack to learn the easy, elegant modern way that works in all browsers. Note that the top answer will have had many moderated edits and there is nothing to indicate that it is wrong. SO used to be amazing, the greatest website ever. But the more you learn about a topic the more you realise that there is some cargo cult copying and pasting going on that is stopping people actually thinking. With 'good enough' search results and 'good enough' content most people are okay - the example I cite will work - but we are sort of stuck. I liken Google search results to a Blockbuster store of old. Sure there are hundreds of videos to choose from but it is an illusion of choice. There is a universe of stuff out there - including the really good stuff - that isn't on the shelves that month. Google are not really that good. They might have clever AI projects and many wonderful things but they have lost the ball and are not really the true trustees of an accessible web.
- tambourine_man 7y ago>you do 'display: grid' and use justify/align: center depending on axis. The code makes sense it is not a hack. It also doesn’t work on IE latest or Edge.
- v_lisivka 7y agoIt's another question: https://stackoverflow.com/questions/50475428/css-grid-is-not-working-on-ie-or-edge https://stackoverflow.com/questions/50475428/css-grid-is-not...
- Theodores 7y agoThe HTML is extremely naive in this question and I wouldn't expect it to work on any computer given the multitude of flaws. Just because the kid who can't walk on two feet can't ride a bicycle doesn't mean all bicycles are broken.
- Theodores 7y agoHave you been reading SO answers?!? It works fine in Edge. Why don't you try? IE latest - there is no such thing. The latest steam engines, the latest CRT screens and the latest buggy whips probably don't do CSS Grid either. IE exists for compatibility with enterprise apps but isn't 'latest'. It is legacy. And the content will still work even if CSS Grid is not supported, just the layout won't be perfect.
- andrewprock 7y agoChecking here: https://netmarketshare.com/browser-market-share.aspx https://netmarketshare.com/browser-market-share.aspx It looks like IE is still the #3 browser, ahead of both Edge and Safari.
- dcbadacd 7y agoHeavily depends on your target market, neither does it just hurt to say "This browser is unsupported for being too outdated" we do it for <noscript> why not <nopropercss> :/
- lrem 7y agoSo, what should I use instead of jQuery these days? The task at hand: set up PhotoSwipe for a completely static list of images.
- tambourine_man 7y agojQuery is still the right tool for a lot of tasks, HN bouble hype notwithstanding.
- bartread 7y agoI agree that it's frustrating (also happens to me all the time) but would argue that it's stackoverflow's fault. They are, after all, supposed to curate the content to make sure it stays relevant, up to and including deleting questions. At the very least it should be easier to get the accepted answer chenged so at least it's at the top of the page (I can't be bothered to spend enough time gaming the system to get the 2000 points necessary to do this).
- astura 7y agoWhat's wrong with using jQuery in 2019?
- crumpets 7y agoIt’s a JavaScript tool that existed 5 years ago.
- SquareWheel 7y agoNo, it's because modern Javascript has now solved the problems that jQuery originally solved. Chiefly DOM manipulation and AJAX requests. It's still a fine library, but jQuery is just no longer needed.
- wongarsu 7y agoWhen I want do do some small DOM manipulation I can now just use standard Javascript, jQuery went from providing an essential service smoothing over browser differences to just providing better syntax in that space. When I want to do more, often React or similar is a better fit. So I end up barely using jQuery anymore. That said, I can imagine quite a few scenarios where it would still be the right tool for the job.
- return1 7y agoi have no problem with the jquery part, the problem is that the same question has a more recent answer so i constantly have to use date filters