This will be another short-ish, stream-of-consciousness post. My goal with this blog for the next several months is just to keep putting thoughts on here to practice my writing on a technical topic. I believe a habit will be more powerful than infrequent bigger efforts. Regularity wins over depth.
I’ve been working with Typescript for a bit over a year now, along with some other things including:
There are other tools and libraries, but those are the big ones. Out of all of these, Typescript is unquestionably my favorite. The things I love in particular are type inference integration with VS Code.
What these things mean for me on a daily basis is that I can forget about which
code calls whichever other code, and use
Find References to tell me what TS
code imports the current export that I’m looking at.
When I compare this to working in Ruby, which was the last language I loved working in, I approximated this by using text search. This worked okay, but brought questions with it like “Ok, I just searched for ‘event’, but is this ‘event’ a reference to what I’m thinking of? Or is it just a variable that shares that name?”. It’s quite a big cognitive load lifted to not have to think about these things.
I suppose when I pause and think about what I’ve written, I’ve described a property of static typing systems and good editor integration. Type inference is an extra layer of sugar allowing me and library authors to do more with less. I’ve worked with Go on a limited basis. I enjoyed the static typing there, too, but I never got into a good flow with editor integration.