📦 @breadstone-infrastructure/style-dictionary
Style Dictionary Plugins for Breadstone projects.
Reusable transforms and preprocessors for Style Dictionary to support advanced design token workflows.
📁 Project Structure
Part of the monorepo mosaik
Package path: infra/style-dictionary-plugins
Version: see npm
License: MIT
📦 Installation
yarn add @breadstone-infrastructure/style-dictionary
npm install @breadstone-infrastructure/style-dictionary
🔧 Usage
In your Style Dictionary config:
const {
shadowCssTransform,
gradientTransform,
nameSnakeUpperCaseTransform,
quoteStringTransform,
listTransform,
letterSpacingTransform,
expandShadowPreprocessor,
lintPreprocessor
} = require('@breadstone-infrastructure/style-dictionary');
StyleDictionary.registerTransform(shadowCssTransform);
StyleDictionary.registerTransform(gradientTransform);
StyleDictionary.registerTransform(nameSnakeUpperCaseTransform);
StyleDictionary.registerTransform(quoteStringTransform);
StyleDictionary.registerTransform(listTransform);
StyleDictionary.registerTransform(letterSpacingTransform);
StyleDictionary.registerPreprocessor(expandShadowPreprocessor);
StyleDictionary.registerPreprocessor(lintPreprocessor);
⚙️ Features
- Custom transforms: shadow, gradient, list, letter spacing, name transforms
- Preprocessors: lint and expand tokens before transformation
- TypeScript-first: fully typed
- Nx Workspace: part of a monorepo for scalable development
🛠 Recommendations
- Use with Style Dictionary for design token management.
- Integrate into your Nx workspace for design system automation.
📦 Publishing
yarn nx run style-dictionary-plugins:publish
📄 License
MIT © Breadstone
Development
This package is part of the Breadstone Nx monorepo.
Use Nx for building and testing:
npx nx run style-dictionary-plugins:build
License
MIT © Breadstone