@cljs-figma/cljs-figma
v0.4.0
Published
Write Figma plugins with ClojureScript. Comes with a browser-based development environment for development without using Figma + all the bells and whistles of ClojureScript development.
Downloads
14
Readme
cljs-figma
Write Figma plugins with ClojureScript. Comes with a browser-based development environment for development without using Figma + all the bells and whistles of ClojureScript development.
Getting Started
Create new plugin inside Figma
Select "Figma Design" (we don't support FigJam just yet)
Select "Empty" so we get a barebones plugin to start with.
Delete the
code.js
file that gets created automaticallyRun
npm init --force --yes
and adjust to your likingInstall
cljs-figma
in the project withnpm install --save-dev cljs-figma
Run
npx cljs-figma-init
to create the basic directory structureInside the
src/main
directory, there will now be two starter files,code.cljs
andui.cljs
Run
npx cljs-figma-dev
to start a in-browser development environmentRun
npx cljs-figma-build
to build the Figma plugin
Expected directory structure
Two main files that are being used as entrypoints.
src/main/plugin/ui.cljs
is loaded as the UI code.src/main/plugin/code.cljs
is loaded in the background context.