Skip to content
HomeVideosBooksBlogs
AllTop postsTopics
Podcasts
HistoryListsWatch laterLiked videosFollowing

The videos, books, blogs and podcasts Hacker News keeps recommending, all in one place.

VideosBooksBlogsPodcastsAboutPrivacySettings

Data from Hacker News, HackerTube, HackerBooks, HackerBlogs and Open Library. Credits · Not affiliated with Y Combinator.

HomeVideosBooksBlogsPodcasts
Ctrl K
    Z

    Zhenghao He

    zhenghao.io · Personal blog · on HN since 2022

    Zhenghao He is a front-end engineer who writes about React, JavaScript and TypeScript, plus system design interviews.

    Visit blogHN submissions
    Web DevelopmentProgrammingLanguages & Compilers
    What HN says

    HN commenters point to his posts on React memoization and system design interviews, and recommend the site to people interested in JavaScript, TypeScript and web development.

    Stats for nerds
    15HN people shared it
    18linked in comments
    381story points
    Jul 2022last shared

    Top posts on HN

    1. 1
      An introduction to type programming in TypeScript
      1 person · 148 points · first shared 2022 · 65 comments on HN
    2. 2
      A complete guide to TypeScript’s 'never' type
      1 person · 95 points · first shared 2022 · 63 comments on HN
    3. 3
      Include debugging in the interview process
      1 person · 67 points · first shared 2022 · 16 comments on HN
    4. 4
      Type Polymorphic Functions in TypeScript
      1 person · 37 points · first shared 2022 · 14 comments on HN
    5. 5
      Preemptive memoization in React is probably not Evil (yet)
      4 people · 9 points · first shared 2022 · Discussion on HN
    6. 6
      When You Should Prefer Map over Object in JavaScript
      3 people · 6 points · first shared 2022 · Discussion on HN
    7. 7
      The Double-Assignment Pattern in jQuery's Source Code
      2 people · 4 points · first shared 2022 · Discussion on HN
    8. 8
      When Does React Render Your Component?
      2 people · 4 points · first shared 2022 · Discussion on HN
    9. 9
      JSON and the Stringification Oddities in JavaScript
      1 person · 4 points · first shared 2022 · Discussion on HN
    10. 10
      Front End vs. Back End System Design Interviews
      2 people · 2 points · first shared 2022 · Discussion on HN

    What HN people wrote when they linked it

    • andrewingramMar 2022

      That's why a number of people (myself included) advocate for overzealous/defensive use of useMemo/useCallback as a means of ensuring that a prop changing is always meaningful. The rationale is summarised here: https://www.zhenghao.io/posts/memo-or-not

      There are good reasons for _not_ doing this, since using these hooks isn't free; and technically speaking useMemo isn't an identity guarantee (though it currently behaves as one), but I haven't experienced any of the common useEffect pitfalls since adopting this methodology a couple of years ago.

      But as my sibling comment points out, a lot of the need for this defensive coding would go away if there were more ways of defining equivalence. I hope that one day the record and tuple proposals land, which should help a bit. But i'd also like to see something like Python's __eq__ and __hash__ in JavaScript too - perhaps done in a similar way to [Symbol.iterator].

    • acemarkeJul 2022

      I would strongly suggest reading through my extensive post "A (Mostly) Complete Guide to React Rendering Behavior" [0], which walks through what "rendering" actually is, what triggers it, React's default behavior, and ways to optimize the behavior by skipping renders for certain components. The post "When Does React Render Your Component?" [1] is also excellent.

      The short summary is that React queues a render when you call some form of `setState()`, renders this component, and by default recursively renders all children inside this component too. Everything else is variations on that idea.

      [0] https://blog.isquaredsoftware.com/2020/05/blogged-answers-a-mostly-complete-guide-to-react-rendering-behavior/

      [1] https://www.zhenghao.io/posts/react-rerender

    • Pr0ject217Feb 2022

      EDIT:

      Paste this hacky snippet into your browser's console to save all of the links into your clipboard:

      (() =>
      {
      let result = [...document.querySelectorAll('td a')]
      .map((link) =>
      link &&
      !link.href.includes('ycombinator') &&
      !link.href.includes('javascript:void')
      ? link.href
      : ''
      )
      .filter(Boolean);
      result = [...new Set(result)];
      result.sort();
      copy(result.join('\n\n'));
      })();

      Just to help, here's a compiled-list of all of the links shared here so…

    • EtheryteJan 2022

      It looks like you submitted the wrong link judging by the title, did you mean https://www.zhenghao.io/posts/system-design-interviews instead ?

    • gururuFeb 2022

      Me, myself: https://www.zhenghao.io/
      Check it out if you are interested in JavaScript, TypeScript, or web development in general

    Related

    Josh Collins-Worthjoshcollinsworth.com42 people

    The blissful Zen of a good side project

    Josh Collins-Worth
    Personal · last shared 2026
    Overreactedoverreacted.io186 people

    Goodbye, Clean Code

    Overreacted
    Personal · last shared 2026
    Andrew H. Farmerandrewhfarmer.com16 people

    "Find your perfect React starter project": a search tool

    Andrew H. Farmer
    Personal · last shared 2017
    James Sinclairjrsinclair.com48 people

    What’s so great about functional programming anyway?

    James Sinclair
    Personal · last shared 2026
    Pony Fooponyfoo.com54 people

    The Controversial State of JavaScript Tooling

    Pony Foo
    Personal · last shared 2022
    SurviveJSsurvivejs.com35 people

    Interview with the author of React-like Inferno about JavaScript optimisations

    SurviveJS
    Personal · last shared 2023
    Christopher Chedeaublog.vjeux.com52 people

    How Javascript Prototypal Inheritance Really works

    Christopher Chedeau
    Personal · last shared 2026
    Dan Abramovmedium.com/@dan_abramov101 people

    A response to “An experienced JavaScript dev’s account of learning React”

    Dan Abramov
    Personal · last shared 2025