Designing composable functional libraries, not just for data visualization
summary
Compost.js is an F# library compiled to JavaScript with Fable->JavaScript and published as an npm package; it models charts as composable primitives (categorical vs continuous scales, shapes, layered composition), uses units of measure to prevent projection errors, and implements an Elmish-style state/update/render pipeline to animate transitions. Demos include UK election bar charts and a Brexit exchange-rate line with eras highlighted; the design composes small primitives into higher-level charts and it works reliably.
AI-written summary · about
chapters (15)
- 0:00Introduction
- 0:26Motivation
- 3:10What are charts
- 7:50Creating a column chart
- 15:12Units of measure
- 16:12Project function
- 17:15Chart
- 21:33Title
- 26:01Design patterns
- 26:30Reusable primitive
- 28:17Layers of obstruction
- 36:46Functional design pattern
- 38:02Compost JS
- 41:08Javascript API
- 44:41Summary
related talks
21mDemo: A functional EDSL for mathematics visualization that compiles to JavaScrip...
40mFrom Zero to Multiplatform: Building a Charts Library in 15 Days
34mThe Gamma: Democratizing data science
30mFlux for Data Visualization: A Preliminary Manifesto
25m(Easier) Interactive Data Visualization in React
37mSupporting Data Journalism through Compilers for Visual Inputs
01h 00mVisualizing Olympic Medals with F# and Fable
20mIntro to LayerChart
