npm.io
1.0.6 • Published 9 years agoCLI

design-tokenize

Licence
Apache-2.0
Version
1.0.6
Deps
0
Vulns
0
Weekly
0

design-token-helper

For converting between sass variables and js/json, this conversion can go in either direction.

At this time, the file must only have variables.

Usage:

"scripts": {
    "tokens": "design-tokenize -i /src/testFile.scss -e .js -o dist"
 },

Will output to a folder named dist testFile.js

testFile.scss contents:

$myVariable: #333;
$anotherVariable: #ff0;

output:

{
    "myVariable": "#333",
    "anotherVariable": "#ff0";
}