Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Answer in Medium article on Design Tokens - Approach B
{
"source": ["tokens_desktop/spacing.json", "tokens_button.json"],
"platforms": {
"desktop": {
"transformGroup": "desktop",
"buildPath": "build/desktop/",
"files": [{
"destination": "tokens.ext",
"format": "my/format"
}]
}
}
}
{
"source": ["tokens_mobile_spacing.json", "tokens_button.json"],
"platforms": {
"mobile": {
"transformGroup": "mobile",
"buildPath": "build/mobile/",
"files": [{
"destination": "tokens.ext",
"format": "my/format"
}]
}
}
}
{
"button": {
"text-icon-spacing": {
"value": "{spacing.lg.value}",
"type": "size"
}
...
}
}
{
"spacing": {
"sm": {
"value": "4",
"type": "size"
},
"md": {
"value": "8",
"type": "size"
},
"lg": {
"value": "12",
"type": "size"
},
"xlg": {
"value": "16",
"type": "size"
}
}
}
{
"spacing": {
"sm": {
"value": "2",
"type": "size"
},
"md": {
"value": "4",
"type": "size"
},
"lg": {
"value": "8",
"type": "size"
},
"xlg": {
"value": "12",
"type": "size"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.