CLI
genart dev
Watch, compile, and serve a live preview
Start a development server that watches a project directory for changes, recompiles automatically, and serves a live preview in the browser with hot reload.
Usage
genart dev <dir> [options]Arguments
| Argument | Required | Description |
|---|---|---|
<dir> | Yes | Path to the developer project directory |
Options
| Flag | Type | Default | Description |
|---|---|---|---|
-p, --port | number | 3456 | Port for the dev server |
--open | boolean | Open the preview in the default browser | |
-o, --output | path | Output path for the compiled .genart file | |
--no-preserve-state | boolean | Discard runtime state on recompile | |
--no-preserve-layers | boolean | Discard design layers on recompile |
Examples
Start the dev server:
genart dev my-project/Start on a custom port and open the browser:
genart dev my-project/ --port 8080 --openStart without preserving state between recompiles:
genart dev my-project/ --no-preserve-stateWrite the compiled file to a specific location:
genart dev my-project/ -o output/sketch.genart