Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bukinoshita/sketch-json
Transform sketch files to json and json to sketch files
https://github.com/bukinoshita/sketch-json
json sketch sketchapp version-control versioning
Last synced: 3 months ago
JSON representation
Transform sketch files to json and json to sketch files
- Host: GitHub
- URL: https://github.com/bukinoshita/sketch-json
- Owner: bukinoshita
- Created: 2017-08-08T16:05:55.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-04T13:24:34.000Z (about 2 years ago)
- Last Synced: 2024-10-10T16:07:35.416Z (4 months ago)
- Topics: json, sketch, sketchapp, version-control, versioning
- Language: JavaScript
- Homepage:
- Size: 876 KB
- Stars: 129
- Watchers: 3
- Forks: 8
- Open Issues: 17
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# sketch-json [![Build Status](https://travis-ci.org/bukinoshita/sketch-json.svg?branch=master)](https://travis-ci.org/bukinoshita/sketch-json)
> Transform sketch files to json and json to sketch files
## Install
```bash
$ yarn add sketch-json
```## Usage
```javascript
const sketchJson = require('sketch-json')sketchJson.toJson().then(() => console.log('Done!'))
// => Done!sketchJson.toSketch().then(() => console.log('Done!'))
// => Done!
```## How it works
Different from [sketch2json](https://github.com/xaviervia/sketch2json), with `sketch-json` you can transform `json` to `sketch` and `sketch` to `json`.
`sketch-json` will generate the `json` files by zipping the `sketch` file and decompressing it. By doing that a sketch folder will be generated with all json files
The idea of this libraries is to prepare json files to be pushed/pull to github/gitlab/etc. Version control for designers!
## Versioning design
## API
### sketchJson
#### .toJson()
Returns a `promise`
Transform Sketch files to json#### .toSketch()
Returns a `promise`
Transform json files to Sketch## Related
* [git-sketch](https://github.com/bukinoshita/git-sketch) — Versioning design with ease
* [sketch-json-cli](https://github.com/bukinoshita/sketch-json-cli) — CLI for this module
* [smiley-sketch](https://github.com/bukinoshita/smiley-sketch) — Smiley sketch
* [terminal-sketch](https://github.com/bukinoshita/terminal-sketch) — Terminal sketch## License
MIT © [Bu Kinoshita](https://bukinoshita.io)