---
title: "Why JavaScript is broken: Effect and TypeScript"
description: "Michael Arnaldi argues that production JavaScript needs one composable model for errors, dependencies, and cleanup."
plain: "Michael Arnaldi says Promises leave errors, cancellation and cleanup hard to compose, and Effect types them in one model."
group: source
speaker: "Michael Arnaldi"
date: 2025-07-14
url: https://youtu.be/und9h4xiIz4
sources:
  - url: https://youtu.be/und9h4xiIz4
    title: "Why JavaScript is Broken: How Effect and TypeScript Fixes It (w/ Michael Arnaldi) - YouTube"
    publisher: "Michael Arnaldi"
    note: "Recording; used for composable errors, dependencies, and resource cleanup."
    accessed: "2026-10-01"
---

# Why JavaScript is broken: Effect and TypeScript

> For agents: start with the [agent guide](https://ratstack.sh/llms.txt). Every page is Markdown by default; add `Accept: text/html` for HTML.

New on /news: [Effect Office Hours 52 with Resonate HQ](/news).

Michael argues that Promise and async/await divide synchronous from asynchronous code while leaving errors, cancellation, and resource cleanup difficult to compose. [07:43](https://youtu.be/und9h4xiIz4?t=463) [10:10](https://youtu.be/und9h4xiIz4?t=610)

He describes Effect as a lazy computation: work described now and executed later, with typed errors and requirements. He distinguishes failures a program handles from defects it lets escape. [11:05](https://youtu.be/und9h4xiIz4?t=665) [12:32](https://youtu.be/und9h4xiIz4?t=752) [23:38](https://youtu.be/und9h4xiIz4?t=1418)

## Sources

1. [Why JavaScript is Broken: How Effect and TypeScript Fixes It (w/ Michael Arnaldi) - YouTube](https://youtu.be/und9h4xiIz4)
   Michael Arnaldi. Recording; used for composable errors, dependencies, and resource cleanup. Accessed 2026-10-01.

## Linked from

- Agent guide → An Effect stack so pure (aspirational) Kit Langton will blush. → [Read page](https://ratstack.sh/llms.txt)

- Change log → What changed in the files served here, newest first. → [Read page](https://ratstack.sh/log)

- Full agent guide → An Effect stack so pure (aspirational) Kit Langton will blush. → [Read page](https://ratstack.sh/llms-full.txt)

- Rat Stack lore | rat-stack → Short, source-grounded notes on the ideas and decisions behind rat-stack. → [Read page](https://ratstack.sh/lore)

- Source change history (log.md) → The generated change log as Markdown. → [Read page](https://ratstack.sh/log.md)
