Skip to content

Commit

Permalink
chore: format generated tokens file
Browse files Browse the repository at this point in the history
  • Loading branch information
DSil committed Feb 8, 2024
1 parent 6ed4f13 commit 2f77766
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/orbit-design-tokens/scripts/fetchBaseTokens.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { $, fetch, fs, path } from "zx";
import prettier from "prettier";
import dotenv from "dotenv-safe";
import dedent from "dedent";
import { solidPaintToWebRgb, toHex } from "figx";
Expand Down Expand Up @@ -150,7 +151,10 @@ async function getColorTokensFromFigma() {
} else {
await fs.writeFile(
path.join(OUTPUT_PATH, `${palette}.json`),
JSON.stringify(saveTokens(palette, tokens), null, 2),
prettier.format(JSON.stringify(saveTokens(palette, tokens), null, 2), {
...prettier.resolveConfig.sync(""),
parser: "json",
}),
);
}
}
Expand Down

0 comments on commit 2f77766

Please sign in to comment.