Dev server
formfeed dev invoice-de
# formfeed dev: invoice-de on http://127.0.0.1:4400
Run it inside a project. Without a slug it opens the first template in alphabetical order. Stop it with Ctrl+C.
- Watches the template's folder, the partials and files folders and
.formfeed/and re-renders on every change; the browser updates over server-sent events. Runningformfeed brand pullin another terminal updates the preview too. - Paged (the default) shows real pages with headers, footers and page numbers, laid out by Paged.js as in the web editor; Flow shows the document as one long page. An image template is always shown in flow, at its pixel size.
- Switch data sets (
data/*.json) and locales (i18n.json) from the toolbar. - Diagnostics panel with the same messages as the web editor (line and column of each finding).
- Serves the project's
files/folder, soasset('logo.png')and relative image paths show the local copy of the file library.formfeed files pullfills the folder from the workspace. - Templates see the brand kit of
.formfeed/brand.jsonasbrand; without the file they see an empty kit.formfeed brand pullwrites it. - True render button when a key is configured (
--api-key,FORMFEED_API_KEYor the keyformfeed loginstored): the PDF or image the API produces from your local files with the selected data set. The panel shows the page count, the units it cost and a link to the file. A test key renders for free; the keyformfeed loginstores is a live key, whose renders count against your plan. Without a key the button is off and everything else works. - For a template that declares
pdf.ua, the preview checks the page it shows and lists what it found under Template check · PDF/UA-1, and a true render shows the validator's verdict with the rules that failed.
Word and PowerPoint templates
formfeed dev also opens a folder with template.docx or template.pptx. There is no local preview of the document itself:
- Edit the file in Word or PowerPoint and save it; the diagnostics panel lists the findings of the tags on every save, by part and paragraph (
word/document.xml ¶12) instead of line and column. - True render fills the document on your machine with the engine the render servers use and converts it to PDF through the API (
POST /pdf/convert), which needs the Starter plan or above. The frame shows that PDF, and after the first true render every saved change renders again. - QR codes, barcodes and SVG pictures are drawn by
@resvg/resvg-js, an optional dependency of the CLI. Without it, and for WebP, GIF and AVIF pictures, which only the render servers draw, the render lists a warning and leaves the picture out.
Flags
| Flag | Meaning |
|---|---|
--port <n> | Port, default 4400 |
--host <host> | Bind address, default 127.0.0.1 |
--open | Open the browser |
--data <name> | Initial data set (data/<name>.json) |
--locale <tag> | Initial locale (from i18n.json) |
Not available yet: --open-in-editor (vscode:// links in diagnostics) and --local-chromium (approximate render with a local Playwright Chromium).
The server binds to 127.0.0.1 by default, so only your own machine reaches it; --host 0.0.0.0 opens it to your network. A port that is in use stops the command with exit code 2; pick another with --port. It needs no account for the offline features.