[Future] TypeScript curriculum + in-browser transpile (pnpm typescript, no CDN) #6

Open
opened 2026-04-26 14:41:22 +00:00 by spikerj · 0 comments
Owner

Summary

Extend the JavaScript track with a TypeScript curriculum using the same runtime via LessonMetadata.Preprocessor = LessonPreprocessor.TypeScript (Node + QuickJS worker run ts.transpileModule before grading).

UI / tooling

  • "Transpile to JavaScript" action in TypeScript lessons.
  • Use the TypeScript compiler in the browser — same API as typescript package (lib/typescript.js); unpkg reference for which artifact to align with.

Dependency policy

  • Add typescript as a first-party pnpm dependency and serve from our build/static assets (or vendor in-repo).
  • No runtime dependency on a third-party CDN for the compiler.

Source

README.md — section TODO / Future work (TypeScript curriculum bullet).

## Summary Extend the JavaScript track with a **TypeScript curriculum** using the same runtime via `LessonMetadata.Preprocessor = LessonPreprocessor.TypeScript` (Node + QuickJS worker run `ts.transpileModule` before grading). ## UI / tooling - **"Transpile to JavaScript"** action in TypeScript lessons. - Use the **TypeScript compiler in the browser** — same API as [`typescript` package](https://www.npmjs.com/package/typescript) (`lib/typescript.js`); [unpkg reference](https://unpkg.com/typescript@latest/lib/typescript.js) for which artifact to align with. ## Dependency policy - Add `typescript` as a **first-party pnpm dependency** and serve from our build/static assets (or vendor in-repo). - **No runtime dependency on a third-party CDN** for the compiler. ## Source `README.md` — section **TODO / Future work** (TypeScript curriculum bullet).
Sign in to join this conversation.