We need to make room for defining build options/properties in our config for tokens build.
As of writing this would be primarily outDir and clean.
We also need to take into account future features such as output build as css and/or json.
Maybe we can take some inspiration from the bundlers/transpilers out there; rolldown, rollup, postcss etc.
Potential schema:
{
"$schema": "packages/cli/dist/config.schema.json",
"outDir": "design-tokens", // deprecated, use output instead
"output": [
{
"action": "create",
"dir": "design-tokens",
"cleanDir": true
},
{
"action": "build-css",
"dir": "design-tokens-build",
"banner": "my banner",
"cleanDir": true
}
],
"clean": true,
"themes": {
"designsystemet": {
"colors": {
"main": {
"accent": "#0062BA"
},
"support": {
"brand1": "#0D7A5F",
"brand2": "#5B3FA0"
},
"neutral": "#24272B"
},
"borderRadius": 4,
"typography": {
"fontFamily": "Inter"
}
}
}
}
We need to make room for defining build options/properties in our config for
tokens build.As of writing this would be primarily
outDirandclean.We also need to take into account future features such as output build as css and/or json.
Maybe we can take some inspiration from the bundlers/transpilers out there; rolldown, rollup, postcss etc.
Potential schema: