node-sketch
node-sketch copied to clipboard
can not read sketch.colors
inspired of demo I do some thing like this
const ns = require('node-sketch');
const fs = require('fs')
ns.read('./test.sketch').then(sketch => {
fs.writeFile('test.js', JSON.stringify(sketch.colors, null, 2)) // => got an empty array []
})
how can I get all colors in some sketch file? sketch version 55.2
Can you try sketch.colorAssets
?
Can you try
sketch.colorAssets
?
ns.read('./test.sketch').then(sketch => {
fs.writeFile('test.js', JSON.stringify(sketch.colorAssets, null, 2)) // => got an empty array too
})
the same result as sketch.colors
Could I get a sketch file to reproduce this issue?
I had the same issue, updating my Sketch to the last version fixed the problem.