At the risk of sounding like a cliché I thought I’d share some thoughts on striking a balance between “speed” and “robustness”, working as a Typescript developer. I’ve always been a firm believer in picking the right tool for the job, whether that is applying the appropriate programming language, framework, library or delivery vehicle (ie. […]
What are Javascript “pure functions”?
Ever hear of ‘pure functions’ in Javascript – and Typescript by extension – and wonder what they are? Pure functions, can simply be described as functions that do not modify their inputs or create side effects. This is important because in Javascript where everything is dynamic by default, it is easy to completely change the […]
Converting a Typescript project from CJS to ESM – the ultimate how-to
The dreaded CommonJS (CJS) to EcmaScript Modules (ESM) conversion. As the Javascript ecosystem continues to evolve and we continue to standardize, one unfortunate side-product for us NodeJS users, is the conversion to ESM.Admitted, as most things Node, since it isn’t running in the browser context we don’t have to convert to ESM, and it likely […]
The game of business, from the perspective of a technical founder
This post will be less about Typescript and more about programming in general, specifically from the point of view of being a technical founder. If you’ve ever dabbled in server administration, fiddled with a raspberry pi, been curious about new technology outside work, or you identify as someone with an explorative or entrepreneurial gene, this […]
To framework, or not to framework, that is the decision
Lately I’ve found myself with renewed urge to learn new things through building new. Usually that starts with a good idea “damn, it would be cool to build X!” – you know the feeling. But being a bit of a perfectionist (it’s something I’m working on), the dreams of features quickly becomes consumed by other […]
What the F are dotfiles and why should I care?
I’m sure we’ve all shared this sort of experience: You grab your recently delivered brand new shiny computer. You’re excited! It’s time to get that baby running, so you plug in the charger and quickly boot it up. Oh snap. It’s faaaaast! Nice! After sprinting through the system configuration and creating a user account, you […]
When to use .d.ts type files for global types
If you don’t already know what a .d.ts file is, I recommend reading my other post on the topic. Writing and managing types for a Typescript project is a cumbersome issue, and one that is often handled differently from project to project. A common pattern that has evolved is to “place types where they are […]
How to get started with Typescript
So, you’ve decided that Javascript is the language you want to pursue and learn. Upon googling “how to learn javascript” you quickly start seeing “Typescript” appearing again and again. Intrigued you wonder “what is Typescript? Is that something I need to know? Should I learn that instead?”. A bit worried you continue your quest for […]
How to work with union types that can be undefined
Ever struggled with figuring out how to deal with undefined? Or spent a good cup of coffee (and a half) to stop the Typescript compiler from screaming at you? In Typescript we often come across values that can have multiple values, called union types, and in some cases one of those values is undefined. If […]
“I love Typescript, but I hate the configuration”
Back upright, posture checked, fingers have just been cracked, you’ve got some good music playing and you’re ready to sit down and start coding on your new cool idea. Whilst ideas begin to unfold in your mind and you’re about to burst with creativity you envision “hey, this would be a cool opportunity to get […]