Allan Deutsch

Learning to think & build in public. Excited about tools for thinking and augmenting human capabilities.

Currently head of product & engineering @GrabbitNFT. Previously product at Microsoft PlayFab, Xbox Live, and Xbox.

Recent notes

Beautifully render code in Svelte

How I transform the code in my markdown files into beautifully rendered snippets on this site.

Linting and formatting a svelte project

Pulling together a bunch of language tools can be a bother, but I find automated formatting & code review tools are worth the hassle.

Type branding removes structural type compatibility

A structural type can be "branded" to add context to values by using the type system for annotations as is done with nominal types. Doing so makes them incompatible with structurally equivalent types.

Resolving CORS errors in SvelteKit

Cross-origin resource sharing requests let a user access resources on one site from another, but only if the server performs the secret CORS handshake with the browser.

Total Typescript notes

I've learned a lot from this course, and use this note to record bits I want to remember and riff on some of my observations.

Pasta Arabica

An improvised pasta dish made to drawn inspiration from the flavors and sounds of the Middle East. It is hearty and surprisingly bright.

TypeScript assertion functions increase type safety

Assertion functions let the programmer narrow types using a named function, making type narrowing much more readable.

Make API misuse hard

Being hard to misuse is an underrated characteristic of exceptional APIs, especially when the possibility needs to be exposed to the client for advanced scenarios.

The publishing pipeline for allandeutsch.com

An overview of how I avoided needing to copy+paste my notes into blogging software to publish them.

Svelte component APIs

There are many ways to Svelte a component...

Slugs make links readable

Special characters aren't valid in URLs, so custom slugs are used to make links easier to read.

Structural types increase data compatibility

Structural types are only concerned with the shape of data, rather than the names of types. This makes data types more compatible.