A Sketch file is a zip file containing a bunch of JSON files.
This package aims to make is easier to manipulate such a file.
npm install sketch-file
There are 4 different methods available:
(filePath: string) => Promise<{
document: FileFormat.Document;
meta: FileFormat.Meta;
user: FileFormat.User;
pages: FileFormat.Page[];
images: {
[id: string]: Buffer;
};
}>
(version?: string) => {
document: FileFormat.Document;
meta: FileFormat.Meta;
user: FileFormat.User;
pages: FileFormat.Page[];
images: {
[id: string]: Buffer;
};
}
({ document, meta, user, pages, images, }: {
document: FileFormat.Document;
meta: FileFormat.Meta;
user: FileFormat.User;
pages: FileFormat.Page[];
images: {
[id: string]: Buffer;
};
}, filePath: string) => Promise<void>
;(seed?: string) => string