Matthew Swensen

  Principal software engineer and open source enthusiast.


10 Stories by Matthew Swensen

Mastering TypeScript mapped types

In this post, we’ll cover mapped types in TypeScript, a real-world example of them, and utility types including Partial, Readonly, and Pick.
4 8 min read

Cascade layers, subgrid, and container queries: What’s new in CSS

Let’s take a cursory look at CSS's newest features being shipped in the near future: cascade layers, subgrids, and container queries.
0 4 min read

Extending object-like types with interfaces in TypeScript

Interfaces are one of TypeScript’s core features. Let’s explore interfaces’ characteristics and how to better leverage them in programs.
1 4 min read

Using tsm as a shebang interpreter in TypeScript

Learn about tsm, a new TypeScript module loader for Node.js that provides native TS support without needing to transpile it to JavaScript first.
0 3 min read

Using SVG vs. Canvas: A short guide

Canvas and SVG allow web developers to draw images onto the screen, but they have very different APIs and approaches to doing so.
0 5 min read

What’s new in TypeScript 4.2

Version 4.2 of TypeScript was released in February 2021, with new features, bug fixes, and performance improvements. Find out more here.
1 2 min read

The case for using frameworks

Frameworks play a critical role in the frontend ecosystem, and leveraging modern frameworks can yield dividends over the life of a project.
0 4 min read

How polymorphic JavaScript functions affect performance

Polymorphic APIs can be convenient to use due to their flexibility, but in some situations, they can be more expensive to execute.
1 5 min read

Creating compound components in React and Angular

What is a compound component pattern in React and Angular, and when should you use one? Read on to learn more.
0 6 min read

Should you drop support for Internet Explorer 11?

Should your app or service continue to invest time in Internet Explorer 11 support? The answer is: it depends. Find out more here.
0 4 min read