Closed wholcman closed 4 years ago
The preview images are generated automatically by sketch (the app) when save the file. This library cannot update these images because it require to render the document to generate them. The only thing that can do is exporting the images with sketch.exportPreviews('path/to/export/')
.
If I export by running sketch.exportPreviews('path/to/export/')
after having updated a attributedString
, the exports are not good.
Do you know this issue ?!
The only solution found is to use directly the CLI sketchtool.
Yes, this library does not re-generate the previews after any change, only can export the previews existing currently in the file.
I'm trying to update text layers of sketch files dynamically like below.
The preview of the new sketch file exported is never updated as if updates have not been taken. I have to manually open the sketch file, save it and now the preview will be OK. You can see the issue in the demo
replace-styles
in the repoAny ideas ?