Enrich the WGSL shader language to support code modules via import and export statements. Linking can be done entirely at runtime.
Projects
A small TypeScript parser combinator library with an efficient regex based lexer.
A command line tool for preprocessing and linking multiple WGSL shader modules into a single WGSL module.
Blog Posts
July 2024
Modern TypeScript enables us to build an improved type constructor to convert union types to intersection types.
June 2024
Use fancy TypeScript type constructors to safely work with Records. Add fields to Records using mapped types. Intersect Records using contravariance. Recover Record types after intersection.
April 2023
Fine grained reactivity (aka signals) libraries are useful for WebGPU. Reactivity libraries offer hooks for lazy recalculation, resource reallocation, cleanup, caching, and dependency tracking.