create-svgsketch-plugin
v0.1.2
Published
Scaffold a new SVGSketch plugin project with TypeScript, dev server, and hot reload
Maintainers
Readme
create-svgsketch-plugin
Scaffold a new SVGSketch plugin project with TypeScript, a dev server, and hot reload.
Usage
npx create-svgsketch-plugin my-plugin
cd my-plugin
npm install
npm run devThat's it. Your plugin is running at http://localhost:9999/index.js with automatic rebuilds on file changes.
What you get
my-plugin/
├── src/
│ └── index.ts ← Your plugin (TypeScript, fully typed)
├── server.js ← Dev server with CORS (auto-started by npm run dev)
├── package.json
├── tsconfig.json
└── README.md- TypeScript with full type checking via
@svgsketch/plugin-sdk - Hot reload — edit
src/index.ts, the bundle rebuilds automatically - Dev server — serves your plugin with CORS headers for Developer Mode loading
- Production build —
npm run buildoutputs a minifieddist/index.js
Loading your plugin in SVGSketch
- Run
npm run devin your plugin directory - Open SVGSketch in your browser
- Go to Settings > Plugins and enable Developer Mode
- Click Add, enter a name and URL:
http://localhost:9999/index.js - Reload the editor
- Open the marketplace (puzzle piece icon) — your plugin appears with a yellow DEV badge
- Enable your plugin and start testing
Scripts
| Command | Description |
|---------|-------------|
| npm run dev | Start dev server + watch for changes |
| npm run build | Production build (minified, single file) |
| npm run check | TypeScript type checking |
Publishing your plugin
When your plugin is ready:
- Run
npm run buildto create the production bundle - Submit your
dist/index.js+ amanifest.jsonthrough the SVGSketch marketplace - After review and approval, your plugin will be available to all SVGSketch users
Documentation
- Plugin Development Guide
- API Reference
- Contributions — tools, panels, commands, menus
- Events & Middleware
- Plugin SDK on npm
License
MIT
