⛱ Broadly scoped ecosystem & mono-repository of 215 TypeScript projects (and ~185 examples) for general purpose, functional, data driven development

Project migrated to Codeberg. The original Github repo is now just a readonly mirror and will be deleted later this year.
- Documentation - Project templates - #HowToThing - Blog posts - Videos - awesome.thi.ng - Generative art projects - Wiki - Latest updates - Algorithms & data structures - DSLs - File / file format / hardware support - Frontend / UI - Fundamentals - Geometry, image & visualization - Iterator, stream & sequence processing - Low-level, binary, memory management, interop - Maths - Network - Randomness - Reactive programming - WebGL / GPGPU - Deprecated packages - Building example projects - Testing - Building API docs - Extracting code examples from readme files & commentsAbout
This is LLM-free, human-made and cared for software, maintained as an ecosystem and anti-framework.
"A collection of functional programming libraries that can be composed
together. Unlike a framework, thi.ng is a suite of instruments and you (the
user) must be the composer of. Geared towards versatility, not any specific
type of music." —
@loganpowell
via Twitter>
Please visit thi.ng for additional information. You might
also find the following tools useful to find & explore projects in this vast
ecosystem:>
- thi.ng tag browser
- tag-based search on the thi.ng website
- repo-wide doc string search
- generated API docs
This project is NOT a framework and all packages can be used in isolation.
Not including deprecations, this mono-repository is home to 216 individual TypeScript libraries/packages/tools and ~185 example projects illustrating their usage, currently totalling ~250k SLOC and ~4350 source files... Some of the projects have been in regular development since 2015. The monorepo exists in its current form since January 2018.
Unlike most other large mono-repos, this one is not for a single project, but a broad collection of jointly developed, yet independent libraries, tools and general purpose building blocks for the following non-exhaustive list of topics (see package overview below):
- Functional programming (ES6 iterators/generators, composition, memoization,
- Reactive programming, stream / transducer based dataflow graphs / pipelines /
- Fiber process tree abstraction for ES6 generators (co-routines / cooperative
- Data structures & data transformations for wide range of use cases (maps,
- WebAssembly bridge APIs & data structure bindings code generators for multiple
- PEG-style functional parser combinators w/ (optional) custom grammar
- Customizable HTML & Markdown parsers
- 2D/3D geometry generation, shape primitives, math, manipulation,
- Canvas abstractions, pixel buffers & SVG serialization/conversion
- Comprehensive function collection (900+) for nD-vectors and matrices (dense &
- ECS implementations with optional support for strided memory layouts
- Semi-declarative WebGL 1/2 abstraction layer
- DSL for shader functions defined in TypeScript and cross-compilation to GLSL,
- Value-based equivalence (vs. native object identity) and associative data
- DSP building blocks: oscillators, noise generators, filters, 1D FFT/IFFT,
- Immutable data handling, state containers, transacted state updates, Undo-Redo
- Reactive UI component toolkits (DOM-based, canvas-based, immediate-mode,
- Multi-format, multi-channel pixel buffers (int & float based), conversions,
- Color space/format conversions, matrix based color manipulation, gradient
- Date-time abstraction, relative dates, iterators, formatters, math
- WebWorker workflow abstractions
- Forth-style pointfree DSL for functional composition and DSL
- S-expression parser & runtime (interpreter) infrastructure for custom DSL
- WASM-based SIMD batch-processing of vector data
- Pen-plotter (AxiDraw) toolchain & geometry conversions
- Interpolations, math helpers, automatic differentiation (Dual numbers)
- etc.
All packages:
- are versioned independently
- have auto-generated online documentation at docs.thi.ng
- built via esbuild and tested via bun.sh
- released via thi.ng/monopub publishing toolchain
- distributed as ESM modules (ES2022 syntax) with export maps, TypeScript
- highly modular with often only a single function / class (incl. closely
- provide re-exports of all their publics for full library imports
- have either none or only
@thi.nginternal runtime dependencies (w/ very few
- declare public interfaces, enums & types in an
api.tsfile - licensed under Apache Software License 2.0
Getting started
A common misconception is to think of this repo as single project. It is not! The sheer number and varied nature & purpose of these packages makes it impossible to provide traditional "Getting started" tutorials — there would have to be dozens of them... To compensate, this repo provides ~180 example projects, detailed package readmes (at the very least for all the larger and/or more important ones), as well as hundreds of small usage examples/snippets in doc strings & readme files.
Documentation
- Generated API docs (overview)
- Single page API docs for all pacakges (work-in-progress)
- Hundreds of usage examples/snippets
Project templates
You might find one of the following template repos an useful starting point (only updated sporadically, make sure to update dependencies manually):
- tpl-umbrella-basic: Bare-bones
- tpl-umbrella-fxhash: Project
- tpl-umbrella-zig: Minimal
#HowToThing
Between August-November 2023, #HowToThing was a series of short posts & mini-tutorials on Mastodon, demonstrating a range of different techniques, patterns and use cases from across the thi.ng/umbrella ecosystem. These are not necessarily intro examples, but each one comes with heavily commented code (and often with visual outputs/results).
- 001: FPS counter with moving average
- 002: Sorting an array by potentially CPU-costly sort criteria
- 003: Multiple key states and extracting commands via FSM
- 004: Creating text-based plots to debug & visualize sequential data
- 005: Barnsley fern IFS fractal
- 006: Clustering arbitrary n-dimensional data using K-means
- 007: Converting Google Maps bookmarks to KML
- 008: CSV parsing into structured data & multi-plot SVG dataviz
- 009: 2D canvas drawing &
threadLast()dataflow operator - 010: Basic web app UI/DOM via Zig/WASM and thi.ng/wasm-api
- 011: 2D cellular automata as WebGL2 multi-pass shader pipeline
- 012: Pure CSS image transition/reveal with thi.ng/hiccup-css
- 013: Lisp interpreter using thi.ng/sexpr & thi.ng/defmulti
- 014: A simple browser REPL for a Lispy mini language
- 015: Generative audio synth offline renderer and WAV file export
- 016: Building a reactive Mastodon UI, parsing & transforming API data
- 017: (Re)Constructing the thi.ng logo as 2D signed-distance field
- 018: Topological sorting, creating & visualizing a task dependency graph
- 019: Building a responsive & reactive stacked column layout
- 020: Generating randomized 4-point 2D multicolor gradient maps/images
- 021: Iterative animated convex polygon subdivision & heat map viz
- 022: Quasi-random voronoi lattice generator
- 023: Tag-based Jaccard similarity ranking/filtering using bitfields
- 024: 2.5D hidden line visualization of digital elevation files (DEM)
- 025: Fitting, transforming & plotting 10k data points per frame using SIMD
- 026: Shader meta-programming to generate animated function plots
- 027: Flocking sim with neighborhood queries to visualize proximity
- 028: Randomized, space-filling, nested 2D grid layout generator
- 029: Forth-like DSL & livecoding playground for 2D geometry generation
- 030: Procedural stochastic text generation via custom DSL & parse grammar
Blog posts
- "Of umbrellas, transducers, reactive streams & mushrooms" (ongoing series):
Videos
The following videos have been migrated from YouTube to their new home at makertube.net (more to come):
- Building a web editor for creating/testing parse grammars
- Building a shader graph editor (WebGL, shader AST transpiler, UI)
- Crash course: TypeScript mapped types in action
Examples & Showcase
There's a steadily growing number (~180) of standalone examples of different complexities (often combining functionality from several packages) in the examples directory.
| Example screenshots | (small selection) | | |-----------------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------| |
|
|
| |
|
|
| |
|
|
|
awesome.thi.ng
Due to other priorities still very much in its infancy & planning stage, but please help to document your own usage of these packages by contributing project information to the awesome.thi.ng repo, which will be used to build a showcase site... Thank you!
Generative art projects
Several generative art projects by Karsten Schmidt on fx(hash) were created exclusively with libraries from this collection.
| De/Frag series | | | |--------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------| |
|
|
| | Quasiflock | C-SCAPE | ASCII-SCAPE | |
|
|
| | Bubblemania | Danza (unreleased) | S-TRACE (unreleased) | |
|
|
|
Community, contributing, getting help
[!NOTE]
My Mastodon account is the best place to
learn about ongoing developments. This is a multi-purpose account, but you can
view #ThingUmbrella tagged
posts only and/or
subscribe to those via RSS.
Join the discussions here on Github, get in touch via Mastodon or use the issue tracker. If you'd like to contribute in other ways, please first read this document.
In general, we welcome contributions of all kinds (docs, examples, bug fixes, feature requests, financial contributions etc.)
**Note: The default branch for this repo is develop and all PRs should be based on this branch. This too means, the README files on this branch might refer to yet-unreleased features or packages. Please use the main branch for viewing the most recently released version(s)!**.
Wiki
To date, the wiki has only been updated sporadically, but please be sure to check it out for project-wide glossary, information, cookbooks, useful snippets etc.
Projects
Latest updates
As of: 2026-07-02
| Status | Package | Version | Changelog | |:----------------------------------------------|:----------------------------------|:--------------------------------------------------------------------------------------------------------|:------------------------------------------| | |
@thi.ng/date | | changelog |
Algorithms & data structures
| Project | Version | Changelog | Description | |-----------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------|-------------------------------------------------------| | @thi.ng/adjacency | | changelog | Adjacency matrices & graph algorithms | |
@thi.ng/arrays | | changelog | Array utilities | |
@thi.ng/associative | | changelog | Alt Set & Map implementations | |
@thi.ng/atom | | changelog | Immutable value wrappers, views, history | |
@thi.ng/bitfield | | changelog | 1D/2D bit field implementations | |
@thi.ng/bidir-index | | changelog | Bi-directional key-value map/index | |
@thi.ng/buffers | | changelog | Generic read/write buffers w/ diff. behaviors | |
@thi.ng/cache | | changelog | In-memory caches / strategies | |
@thi.ng/cellular | | changelog | Highly configurable 1D Cellular automata | |
@thi.ng/column-store | | changelog | Extensible in-memory column store database | |
@thi.ng/dcons | | changelog | Doubly-linked list | |
@thi.ng/diff | | changelog | Array & object diffing | |
@thi.ng/disjoint-set | | changelog | Disjoint Set data structure | |
@thi.ng/dgraph | | changelog | Dependency graph | |
@thi.ng/ecs | | changelog | Entity-Component System | |
@thi.ng/gp | | changelog | Genetic programming helpers / AST gen | |
@thi.ng/heaps | | changelog | Binary & d-ary heap impls | |
@thi.ng/idgen | | changelog | Versioned ID generation / free-list | |
@thi.ng/k-means | | changelog | K-means clustering of n-D data | |
@thi.ng/leaky-bucket | | changelog | Counter-based Leaky Bucket implementation | |
@thi.ng/ramp | | changelog | Parametric, interpolated lookup tables | |
@thi.ng/quad-edge | | changelog | Quad-edge, dual-graph data structure | |
@thi.ng/resolve-map | | changelog | DAG computations & value resolution | |
@thi.ng/sorted-map | | changelog | Sorted map & set datastructure | |
@thi.ng/sparse-set | | changelog | Sparse set datastructure | |
@thi.ng/tensors | | changelog | 1D-4D tensors, views & operations | |
@thi.ng/text-analysis | | changelog | Tokenization, statistics, vector encoding, clustering | |
@thi.ng/trie | | changelog | Trie-based map datastructure w/ prefix queries | |
@thi.ng/vclock | | changelog | Vector clock functions / comparators | |
@thi.ng/zipper | | changelog | Immutable tree editing / navigation |
DSLs
| Project | Version | Changelog | Description | |-------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------|-----------------------------------------------------|-----------------------------------------------| | @thi.ng/lispy | | changelog | Extensible, interpreted Lisp-style DSL | |
@thi.ng/pointfree | | changelog | Stack-based DSL & functional composition | |
@thi.ng/pointfree-lang | | changelog | Forth-like syntax layer for @thi.ng/pointfree | |
@thi.ng/proctext | | changelog | Procedural text generation engine | |
@thi.ng/sexpr | | changelog | S-Expression parser & runtime infrastructure |
File / file format / hardware support
| Project | Version | Changelog | Description | |-------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------|-------------------------------------------------| | @thi.ng/axidraw | | changelog | Minimal, declarative AxiDraw plotter controller | |
@thi.ng/bencode | | changelog | Bencode binary format encoding | |
@thi.ng/csv | | changelog | Customizable CSV parser/object mapper | |
@thi.ng/dot | | changelog | Graphviz DOM & export | |
@thi.ng/dsp-io-wav | | changelog | WAV file format exporter | |
@thi.ng/egf | | changelog | Extensible Graph Format | |
@thi.ng/file-io | | changelog | Assorted file I/O utils for NodeJS | |
@thi.ng/geom-io-obj | | changelog | Wavefront OBJ model parser | |
@thi.ng/hiccup-css | | changelog | CSS from nested JS data structures | |
@thi.ng/hiccup-html | | changelog | Type-checked HTML5 element wrappers for hiccup | |
@thi.ng/hiccup-html-parse | | changelog | HTML parsing & transformation to hiccup format | |
@thi.ng/hiccup-markdown | | changelog | Hiccup-to-Markdown serialization | |
@thi.ng/hiccup-svg | | changelog | hiccup based SVG vocab | |
@thi.ng/iges | | changelog | IGES format geometry serialization | |
@thi.ng/markdown-table | | changelog | Markdown table generator / formatter | |
@thi.ng/mime | | changelog | File extension to MIME type mappings | |
@thi.ng/msgpack | | changelog | Msgpack serialization/deserialization | |
@thi.ng/pixel-io-geotiff | | changelog | GeoTIFF reader support for thi.ng/pixel | |
@thi.ng/pixel-io-netpbm | | changelog | 1/8/16/24bit NetPBM image format reader/writer | |
@thi.ng/pixel-io-pfm | | changelog | Portable FloatMap image format reader/writer | |
@thi.ng/pixel-io-tiff | | changelog | Minimal TIFF reader | |
@thi.ng/prefixes | | changelog | Linked Data, RDF & xmlns prefixes/URLs | |
@thi.ng/sax | | changelog | SAX-like XML parser / transducer | |
@thi.ng/tangle | | changelog | Literate programming utilities |
Frontend / UI
| Project | Version | Changelog | Description | |-----------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------|--------------------------------------------------| | @thi.ng/blurhash | | changelog | Fast image blurhash encoder/decoder | |
@thi.ng/canvas | | changelog | Canvas creation & HDPI support helpers | |
@thi.ng/dl-asset | | changelog | Asset/canvas/file download helpers | |
@thi.ng/emoji | | changelog | Bi-directional emoji lookup tables (names/chars) | |
@thi.ng/hdiff | | changelog | String diffing w/ hiccup output (includes CLI) | |
@thi.ng/hdom | | changelog | Hiccup based VDOM & diffing | |
@thi.ng/hdom-canvas | | changelog | hdom adapter for hiccup-canvas | |
@thi.ng/hdom-components | | changelog | hdom based UI components | |
@thi.ng/hdom-mock | | changelog | hdom mock implementation (testing / prototyping) | |
@thi.ng/hiccup | | changelog | S-expression based HTML/XML serialization | |
@thi.ng/hiccup-canvas | | changelog | hiccup interpreter for canvas api | |
@thi.ng/hiccup-carbon-icons | | changelog | IBM Carbon icons in hiccup format | |
@thi.ng/imgui | | changelog | Immediate mode GUI | |
@thi.ng/interceptors | | changelog | Composable event handlers & processor | |
@thi.ng/meta-css | | changelog | CSS framework codegen, transpiler, bundler | |
@thi.ng/rdom | | changelog | Reactive, diff-less, async UI components | |
@thi.ng/rdom-canvas | | changelog | rdom component wrapper for thi.ng/hiccup-canvas | |
@thi.ng/rdom-components | | changelog | Unstyled, customizable component collection | |
@thi.ng/rdom-forms | | changelog | Datadriven HTML form generation | |
@thi.ng/router | | changelog | Customizable browser & non-browser router | |
@thi.ng/text-canvas | | changelog | Text-mode canvas, drawing, tables, charts | |
@thi.ng/text-format | | changelog | Color text formatting w/ ANSI & HTML presets | |
@thi.ng/text-format-image | | changelog | Bitmap image formatting for CLI/Terminal |
Fundamentals
| Project | Version | Changelog | Description | |---------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------|----------------------------------------------------------| | @thi.ng/args | | changelog | Declarative & functional CLI arg parsing & coercions | |
@thi.ng/api | | changelog | Common types, decorators, mixins | |
@thi.ng/bench | | changelog | Basic benchmarking helpers | |
@thi.ng/checks | | changelog | Type & value checks | |
@thi.ng/compare | | changelog | Comparators | |
@thi.ng/compose | | changelog | Functional composition helpers | |
@thi.ng/date | | changelog | Date/time iterators, formatters, rounding | |
@thi.ng/defmulti | | changelog | Dynamic multiple dispatch | |
@thi.ng/distance | | changelog | n-D distance metrics & K-nearest neighborhoods | |
@thi.ng/equiv | | changelog | Deep value equivalence checking | |
@thi.ng/errors | | changelog | Custom error types | |
@thi.ng/expose | | changelog | Conditional global variable exposition | |
@thi.ng/fibers | | changelog | Process hierarchies & ops for cooperative multitasking | |
@thi.ng/hex | | changelog | Hex value formatters for U4-64 words | |
@thi.ng/logger | | changelog | Basis infrastructure for arbitrary logging | |
@thi.ng/memoize | | changelog | Function memoization w/ customizable caching | |
@thi.ng/metrics | | changelog | Computing & aggregating value metrics (mean, range, sd) | |
@thi.ng/object-utils | | changelog | Plain JS object & map manipulation | |
@thi.ng/oquery | | changelog | Pattern based query engine for JS objects | |
@thi.ng/parse | | changelog | Parser combinators & AST generator/transformer | |
@thi.ng/paths | | changelog | Immutable nested object accessors | |
@thi.ng/strings | | changelog | Higher-order string formatting utils | |
@thi.ng/system | | changelog | Minimal life cycle container for stateful app components | |
@thi.ng/timestamp | | changelog | Timestamp abstraction/wrapper | |
@thi.ng/transclude | | changelog | Template engine for text document generation | |
@thi.ng/units | | changelog | Extensible SI unit conversions | |
@thi.ng/validate | | changelog | Composable functional data validation | |
@thi.ng/validate-schema | | changelog | JSON schema validation |
Geometry, image & visualization
| Project | Version | Changelog | Description | |---------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------|-----------------------------------------------------| | @thi.ng/boids | | changelog | Configurable n-dimensional boids simulation | |
@thi.ng/color | | changelog | Color conversions, gradients | |
@thi.ng/color-palettes | !
README truncated. [View on GitHub