Skip to content

Commit 13ea3a3

Browse files
committed
Update split json script for new naming convention
1 parent 1273f90 commit 13ea3a3

4 files changed

Lines changed: 678 additions & 911 deletions

File tree

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

split-json.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const jsonData = JSON.parse(rawData);
1515
const baseDir = path.join(__dirname, "tokens/tokens-figma");
1616

1717
// Define keys to include
18-
const includeKeys = ["GLOBAL/core", "GLOBAL/semantic"];
18+
const includeKeys = ["00 Core", "01 Semantic"];
1919

2020
// Function to write data to file
2121
const writeFile = (filePath, data) => {
@@ -27,7 +27,7 @@ const writeFile = (filePath, data) => {
2727
includeKeys.forEach((key) => {
2828
if (Object.prototype.hasOwnProperty.call(jsonData, key)) {
2929
// Split the key into parts
30-
let keyParts = key.split("/");
30+
let keyParts = key.split(" ");
3131

3232
// Remove the first part if there are multiple parts
3333
if (keyParts.length > 1) {

0 commit comments

Comments
 (0)