Skip to main content

86 posts tagged with "TypeScript"

The TypeScript programming language.

View All Tags

Bulletproof uniq with TypeScript generics (yay code reviews!)

· 5 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

Never neglect the possibilities of a code review. There are times when you raise a PR and all you want is for everyone to hit approve so you can merge, merge and ship, ship! This can be a missed opportunity. For as much as I'd like to imagine my code is perfect, it's patently not. There's always scope for improvement.

Web Workers, comlink, TypeScript and React

· 10 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

JavaScript is famously single threaded. However, if you're developing for the web, you may well know that this is not quite accurate. There are Web Workers:

A worker is an object created using a constructor (e.g. Worker()) that runs a named JavaScript file — this file contains the code that will run in the worker thread; workers run in another global context that is different from the current window.

If you're using Vite to build your React app, you may prefer to read this post.

Definitely Typed: The Movie

· 50 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

This post is a a little different from most that sit on my site. It's the story of the Definitely Typed project, of which I was an early member. It had a seismic impact on the development of TypeScript. When exchanging messages with Andrew Branch (member of the TypeScipt team), I realised it was an untold story, and perhaps I should tell it, before I forget! So I did, and this is it.

I named it "Definitely Typed: The Movie" as the name entertained me. Little did I know, that a few years later, a documentary would be made about TypeScript, and I'd be in it; in part thanks to writing this history. You can see more about that here.

For now, back to Definitely Typed...

A title image that reads "Definitely Typed: The Movie"

TypeScript and webpack: Watch It

· 3 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

All I ask for is a compiler and a tight feedback loop. Narrowing the gap between making a change to a program and seeing the effect of that is a productivity boon. The TypeScript team are wise cats and dig this. They've taken strides to improve the developer experience of TypeScript users by introducing a "watch" API which can be leveraged by other tools. To quote the docs:

Semantic Versioning and Definitely Typed

· 5 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

This a tale of things that are and things that aren't. It's a tale of semantic versioning, the lack thereof and heartbreak. It's a story of terror and failing builds. But it has a bittersweet ending wherein our heroes learn a lesson and understand the need for compromise. We all come out better and wiser people. Hopefully there's something for everybody; let's start with an exciting opener and see where it goes...

Auth0, TypeScript and ASP.NET Core

· 10 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

Most applications I write have some need for authentication and perhaps authorisation too. In fact, most apps most people write fall into that bracket. Here's the thing: Auth done well is a *big* chunk of work. And the minute you start thinking about that you almost invariably lose focus on the thing you actually want to build and ship.

ts-loader 2017 retrospective

· 5 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

2017 is drawing to a close, and it's been a big, big year in webpack-land. It's been a big year for ts-loader too. At the start of the year v1.3.3 was the latest version available, officially supporting webpack 1. (Old school!) We end the year with ts-loader sitting pretty at v3.2.0 and supporting webpack 2 and 3.

The TypeScript webpack PWA

· 4 min read
John Reilly
OSS Engineer - TypeScript, Azure, React, Node.js, .NET

So, there you sit, conflicted. You've got a lovely build setup; it's a thing of beauty. Precious, polished like a diamond, sharpened like a circular saw. There at the core of your carefully crafted setup sits webpack. Heaving, mysterious... powerful.