Ask HN: What's a good TS codebase to learn from?

10 points | by jcuenod 9 days ago


  • PaulHoule 9 days ago
    The TS compiler itself. It is twice as effective a use of your time because: (1) it is a good high-complexity code base, (2) teaches you about TS internals.
  • ecesena 9 days ago
    I can recommend Nest (note: not nextjs) is a framework for building webapps/microservices in TS. If you build an app using nest, the framework is going to give you a level of structure that you may like.

    In terms of learning by reading nest's source, I don't think it's the most readable code out there - but there's certainly a lot to learn about abstractions. On the opposite spectrum, if you're really starting from 0 maybe find a few apps done in nest that go a little beyond the basics covered by the tutorials.

    (I have no affiliations with nest, I'm just using it for my own project and I certainly learned a lot from the framework.)

    • yarinr 9 days ago
      You could try looking into the VS Code codebase [0]. I wouldn't say it's considered an 'ideal' codebase, but it's definitely a large and well-maintained one.


      • swah 8 days ago
        IMO just ask for help on /r/typescript or some Discord server regarding the specific issues. The documentation is pretty good IMO.

        What makes things a little bit more complicated is that the language is still changing so some answers on StackOverflow might be outdated.

        OTOH, I just use any all the time...

        • ianpurton 9 days ago
          The ProtonMail client is worth a look.

          It's a react frontend build with typescript.