DTCG 2025.10
Full support for the stable Design Tokens specification — resolver documents, sets, modifiers, and all token types.
DTCG 2025.10
Full support for the stable Design Tokens specification — resolver documents, sets, modifiers, and all token types.
6 Output Formats
CSS custom properties, JSON, JS/TS modules, Tailwind CSS v4, Swift/SwiftUI, and Kotlin/Jetpack Compose — all built in.
Extensible Pipeline
Custom preprocessors, filters, transforms, and renderers. Build exactly the output your platform needs.
In-Memory Mode
Run without the filesystem for build tools, APIs, testing, and serverless environments.
Dispersa processes tokens through a pipeline:
Resolve → Preprocess → Parse → Global Filter → Global Transform → Filter → Transform → RenderLoads the DTCG resolver document, merges sets in order, and applies modifier contexts (themes, platforms, densities) to produce the raw token tree for each permutation.
Define your tokens in DTCG format, configure a resolver document with sets and modifiers, then build output for every platform from a single source of truth.
import { Dispersa, css } from 'dispersa'import { colorToHex, nameKebabCase } from 'dispersa/transforms'
const dispersa = new Dispersa({ resolver: './tokens.resolver.json', buildPath: './dist',})
await dispersa.build({ outputs: [ css({ name: 'css', file: 'tokens.css', preset: 'bundle', transforms: [nameKebabCase(), colorToHex()], }), ],})