0.1.17 • Published 6 years ago

seact v0.1.17

Weekly downloads
44
License
MIT
Repository
github
Last release
6 years ago

Seact

| under development

example

import Seact from 'seact'
import sketch from 'sketch/dom'

const document = sketch.getSelectedDocument()
const page = document.selectedPage

Seact.render(
  <group lock adjustToFit style={{ backgroundColor: '#e43', borderColor: '#ddd' }}>
    <text frame={{ x: 200, y: 200, widht: 200, height: 200 }} text="hello wolrd" />
  </group>,
  page,
)

usage

The library help build constructed layers to sketch board by jsx which uses the javascript API. To use this library, you should ensure your sketch version >= v49. And it is recommended to init your project through skpm.

insallation

npm install --save-dev seact

babel config

The example above ensure you're using compiler to transfrom jsx to valid javascript code like babel.

If you are using babel, you should install plugin to transform jsx

npm install --dev babel-plugin-transform-react-jsx

Then you should set config in .babelrc:

{
  "plugins": [["transform-react-jsx", { "pragma": "Seact.h" }]]
}
0.1.17

6 years ago

0.1.16

6 years ago

0.1.12

6 years ago

0.1.10

6 years ago

0.1.9

6 years ago

0.1.8

6 years ago

0.1.7

6 years ago

0.1.6

6 years ago

0.1.4

6 years ago

0.1.3

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago

0.0.27

6 years ago

0.0.26

6 years ago

0.0.25

6 years ago

0.0.24

6 years ago

0.0.23

6 years ago

0.0.22

6 years ago

0.0.21

6 years ago

0.0.20

6 years ago

0.0.19

6 years ago

0.0.18

6 years ago

0.0.17

6 years ago

0.0.16

6 years ago

0.0.16-0

6 years ago

0.0.15

6 years ago

0.0.14

6 years ago

0.0.13

6 years ago

0.0.12

6 years ago

0.0.11

6 years ago

0.0.10

6 years ago

0.0.9

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago