David Walsh

davidwalsh.name · Personal blog · on HN since 2007

David Walsh is a web developer who writes JavaScript, CSS and browser API tutorials, plus occasional career posts and interviews.

What HN saysHN commenters point to his git aliases series and JavaScript posts as worthwhile reading; the given comments offer little direct opinion otherwise.
222HN people shared it
62linked it in comments
268stories submitted
3.1Kstory points
5 months agolast shared
2007people per year2026

Most-shared posts

  1. 1
    Interview with a Pornhub web developer (2019)
    9 people · 342 points · first shared 2019 · 214 comments on HN
  2. 2
    Imposter Syndrome
    7 people · 14 points · first shared 2015 · 1 comments on HN
  3. 3
    JS Objects: Inherited a Mess
    4 people · 78 points · first shared 2013 · 74 comments on HN
  4. 4
    CSS vs. JS Animation: Which is Faster?
    4 people · 77 points · first shared 2014 · 17 comments on HN
  5. 5
    Fetch API
    4 people · 10 points · first shared 2015 · 3 comments on HN
  6. 6
    “I Don't Hate Arrow Functions” Blog Post
    4 people · 9 points · first shared 2019 · 2 comments on HN
  7. 7
    Event Delegation
    4 people · 5 points · first shared 2011 · discussion on HN
  8. 8
    HTML5 Context Menus
    4 people · 4 points · first shared 2012 · discussion on HN
  9. 9
    Rta label
    4 people · first shared 2019
  10. 10
    CSS4 Preview – Selectors
    3 people · 93 points · first shared 2011 · 34 comments on HN
  11. 11
    Being a Dev Dad
    3 people · 53 points · first shared 2016 · discussion on HN
  12. 12
    Nudity detection with JavaScript
    3 people · 8 points · first shared 2012 · discussion on HN
  13. 13
    JS Objects: Distractions
    3 people · 6 points · first shared 2013 · 1 comments on HN
  14. 14
    HTML5 Link Prefetching
    3 people · 2 points · first shared 2012 · discussion on HN
  15. 15
    More HTML5 APIs
    2 people · 223 points · first shared 2012 · 67 comments on HN

What HN people wrote when they linked it

wyclif · 2022-01-17
The previous entry in the series is also worthwhile: https://davidwalsh.name/awesome-git-aliases
skrebbel · 2015-06-25
I like the idea, it's a bit like how lazy list processing works, but then applied to promises. However, I don't completely see the appeal as soon as ES6 or ES7 transforms with a tool like Babel are ok for you. ES7 is probably going to have C#-like async/await syntax[0], which takes this problem away entirely and in a much less complicated matter. This syntax works great today with babeljs. And even if you don't dare using experimental ES7 features yet, you can accomplish just about exactly the same with ES6 generators[1]. If you really really need to avoid compiling your code, then I can see the appeal of this "pseudosynchronous" idea, but I do feel that it's much more complex and error prone than setting up a build process instead. [0] https://github.com/lukehoban/ecmascript-asyncawait [1] http://davidwalsh.name/async-generators
lalwanivikas · 2015-05-22
IMO rating would be a difficult thing to do as there are many factors[1] to consider. What best for one use case, might be the worst choice for another. A more qualitative comparison would be more useful: http://www.fusioncharts.com/javascript-charting-comparison/ [1] http://davidwalsh.name/13-factors-choosing-javascript-charting-library
hayksaakian · 2013-08-03
It works great but what if we want the input to have the focus when the page loads? jQuery right? We grab the input and we call the focus() method in it. NO. With directives we want our HTML to be as self-descriptive as possible so we are going to create a focus directive. Or you could use html5's autofocus http://davidwalsh.name/autofocus and cut the JS ----- Otherwise great article, I'm really leaning hard towards angular now, over ember
mcrittenden · 2012-07-18
Hmm, looks like setting a default in Firefox is more difficult than I thought. I'm a Chrome user, but I could have sworn when you added a custom search engine in FF then it showed up in the list from "Manage Search Engines" but it appears that's not the case now (maybe never was?), and that the recommended way is by using OpenSearch XML[1]. I'll get that in place and update when it's done. Thanks for the bug report! 1: http://davidwalsh.name/open-search
Brybry · 2023-07-09
The Louisiana law is being challenged [1] I don't get why we can't instead have regulation requiring porn websites to implement adult content rating meta tags, which most porn sites already do (look at the site source sometime). [2][3] Then let parents use content blockers and/or built-in parental controls. If we need even more regulation after that then require platforms to provide parental controls to block tagged content (which I assume they generally already do anyway?) It's not like the sites that don't implement rating meta tags are going to follow these more strict ID verification laws. In my opinion, I feel like these laws are not really about protecting children (which most everyone supports), as I don't see that they will meaningfully do so. That makes me think they're instead about conservative political points at the expense of annoying adults. [1] https://www.nola.com/gambit/news/the_latest/groups-file-free-speech-la… [2] https://developers.google.com/search/docs/crawling-indexing/safesearch [3] https://davidwalsh.name/rta-label
steve_adams_86 · 2020-10-07
> To the 18 year old David who sat in that lonely computer lab: you fucking did it, dude. You lived that dream. To 37 year old David: Go do it again. I really enjoyed that part. I forget sometimes that my career - what I woke up to do this morning, the reason I'm in this office right now - this was my dream. I should remember that more often. This dream started almost 20 years ago (I'm about the same age as David) and it's easy to forget... I thought this would be impossible once. Well, the odds looked pretty bad at first. I barely scraped by in school, would never enter post secondary school, and at the time was terrible with math and logic. I didn't care about programming specifically though, I cared about what I could create with it. In retrospect, I'm glad I had the attitude and optimism that I did. More on topic, I know of David through his website which, early on on my front end days, was an incredibly helpful resource. I vividly remember figuring out Mootools problems with the help of his articles. Ha, like this: https://davidwalsh.name/namespace-mootools So out of date now, but man, some of his stuff saved my ass when I was thrown into a Mootools-heavy project in 2011-2012 with very little experience with JS. Great memories.
_getify · 2015-09-08
> `var` is broken Nonsense. Revisionism at its finest. But that's an argument I made in a different blog post: http://davidwalsh.name/for-and-against-let > It would be nicer to have real, deep immutability, but `const` isn't it. Yep, agree with you on that. That was one of the main points of my post. > Because `const` requires to be initialized at the time of definition, you know the variable is valid for its entire lifetime. No, that's where you're mistaken. All you really know is that the variable assignment is reliable. If the assignment happens to be of an immutable value, great. But given the choice between these two guarantees: 1. The assignment is immutable 2. The value is immutable (1) is almost pointless -- and a quick scan of your small block where it's scoped will verify that or not. (2) is the absolute important one. `const` masquerades as (2) when it's really only (1). That's what I don't like about it.
jaysonelliot · 2012-10-04
It's a fun visualization to have up as a dashboard, I think I'll keep it running during the debates. I love the design; it's very easy to read, and the simplicity and color make it easy to digest information at a glance. My constructive criticism: For the word frequency charts at the top of the screen, I'd weed out common words, and/or try to combine words into meaningful phrases. http://www.wordle.net/ does a good job with this (weeding out common words, not discerning phrases). The number one thing I think people would be interested in would be some kind of sentiment analysis. Perhaps a knowledgable HN'er could suggest a service you could use for this? From a UX perspective, I'd like the ability to pause and rewind the twitter streams, or filter them for specific words, phrases, geographic locations, or demographics. One final nitpick, I would suggest using image meta-tags for sharing on Facebook. I posted the live.votizen.com page to my timeline, and there was no image to accompany the link. Here are the meta-tags you can use for richer sharing: http://davidwalsh.name/facebook-meta-tags But yes, overall, I love this.
rany_ · 2024-03-14
Well, if implemented properly I think it's OK. Back in the Internet Explorer days, Microsoft used to block adult sites on device based on the RTA header adult sites added themselves. I think if adult sites were required to use the RTA header and device manufacturers/OS/browser makers forced to obey it; it's an OK compromise. All the well known adult sites are already using it, it's just up to the browser makers to support it again... and besides, with on-device AI they don't even need to only rely on the RTA header if they want to make their implementation more advanced. More info: https://davidwalsh.name/rta-label
basil-rash · 2024-01-30
That'd be the "equivalent meta tag" I mentioned. And this site claims the header works too, though I haven't tested it myself. https://davidwalsh.name/rta-label
jonatron · 2023-05-29
https://davidwalsh.name/event-delegate By David Walsh on March 7, 2011 One of the hot methodologies in the JavaScript world is event delegation, and for good reason.
muzani · 2023-01-28
Pornhub uses nginx and it's a top 5 website in traffic. Source: https://davidwalsh.name/pornhub-interview
afavour · 2022-02-10
Yes, the correct way (these days) to detect what the OP actually wants is the pointer media query: https://davidwalsh.name/pointer-media-query Which has values for coarse (finger) and fine (mouse, tablet, etc)
mynegation · 2021-07-11
This is a nice idea! I once whipped up a shell script to do the same thing. UX feedback - disable autocorrections on the input fields [1], you may want to trim white space as well. [1] https://davidwalsh.name/disable-autocorrect
edoceo · 2021-06-09
No. I started here https://davidwalsh.name/how-to-build-firefox - it mostly "just worked". I'm on Gentoo so I already had all the build-deps (oh, I had to enable some PulseAudio crap tho)
gvb · 2021-06-05
Someone on the internet says Apple iOS does support it: https://davidwalsh.name/how-to-use-jpeg-2000-jp2-for-a-faster-images-o…
SahAssar · 2020-12-24
I usually use a inlined base64 encoded favicon for that purpose like this: https://davidwalsh.name/blank-favicon
mikece · 2020-06-19
There is a feature of OBS called OBS-VirtalCam that presents your "program output" as a webcam on your system which you could select as your webcam input on Zoom... or Skype or Teams or anything else. https://davidwalsh.name/obs-webcam
c-smile · 2020-04-30
Agree with the rejection. The same link in different contexts can be as either external or local. So that is a business of UA/renderer to mark it properly. CSS is quite adequate for that (https://davidwalsh.name/external-links-css) and the image (or whatever author/UA decided to use) can go inline in CSS itself.
LinuxBender · 2019-10-16
If they had kept the requirement simple (such as adding the RTA header) [1] and requiring browser developers to recognize the RTA header, then they would not have had the complexity and doubts currently in play. That would have pushed the requirement, liability and decision onto the parents as to whether or not adult content was appropriate. [1] - https://davidwalsh.name/rta-label
wishinghand · 2019-03-19
I'm wondering if it's this: https://davidwalsh.name/javascript-proxy
davidwalshblog · 2017-11-29
Cloudinary's new Video feature is actually really, really good: https://davidwalsh.name/cloudinary-video-player
claviska · 2017-08-01
Problem is like I described here: https://davidwalsh.name/shoelace-css TL;DR – most people just use the bundle because they don't want to setup a preprocessor.
cturhan · 2017-04-19
Web is the most evolving technology. Unlike a java or c developer, web developer should refresh himself everyday. Doesn't matter if one is 1 or 10 year developer. With a 5 year experience, I must confess I feel like I know a few. Here is a good article[1] by David Walsh describing this feeling. At an interview, I can say I wrote apps with Vue, Angular 1.x and React but if they ask a question like "how to add a new cookie with specific domain using JS", I can't code without googling. [1] https://davidwalsh.name/impostor-syndrome
djmashko2 · 2016-10-23
I maintain a few open source projects, and found this list to align very closely with my own desires: https://davidwalsh.name/45-github-issues-dos-donts Some highlights: - Do submit one pull request to address one issue. - Do submit two pull request to address two issues. - Do not tack on a minor whitespace or semicolon changes in unrelated commits or Pull Requests, even if the minor change is correct. Make a dedicated commit or Pull Request instead. In general, the smaller and easier to understand a PR is, the easier to merge. I've seen a lot of PRs lose their way due to a "while I'm here" mentality of fixing code style etc, and it often obscures the real purpose of the contribution.
brianwawok · 2016-03-21
What kind of tools do you suggest? Google shows me: https://davidwalsh.name/uncss (I think for dynamic) https://unused-css.com/ (I think also works for dynamic) and a bunch more
max_ · 2016-02-25
you can use https://davidwalsh.name/nudejs to detect their posts and then: Ban them!!

Keyboard shortcuts

/Search
j kNext / previous blog
EnterOpen selected blog
vVisit the blog site
fFollow / unfollow
lSwitch grid / list view
dSwitch dark mode
g hHome
g pTop posts
g tTopics
g fFollowing
g lLiked
g yHistory
g qFAQ
EscBack / close