Anticode Open builder

Code-to-canvas sync: outside edits appear on the canvas, with an undo

When a coding agent, the CLI or an assistant over MCP changes a project you have open, the builder notices within about fifteen seconds, redraws the canvas from the new version and puts a note in the build log with an Undo button. Every save carries the version it was based on, so two editors can't silently overwrite each other.

Updated · By the Anticode team

The problem with two editors

Once a project can be edited from more than one place, the usual failure is quiet: you change a heading in the browser, your agent changes the prices in the same file a moment later, and whichever save lands last wins. Nobody sees an error; one change is simply gone. To sync coding agent edits to website builder sessions safely, both sides need to know which version they started from, and the side that's behind has to find out before it writes.

How the open builder keeps up

When you're signed in, the project open in the builder is mirrored to your account. While the builder is open and its tab is visible, it asks the server for the project when the window gets focus and every fifteen seconds after that. There's no live socket; it's a small, regular check. If the server's version number has moved and its content differs from what's on screen, the builder:

  1. Keeps a copy of what you had.
  2. Redraws the canvas from the server's version with the same design engine, and runs the design and security checks again, so the status line and Report tab describe what you're now looking at.
  3. Adds a note to the build log: Updated from outside Anticode, with the line "A coding agent or the CLI changed this project. The canvas now shows their version."
  4. Offers Undo on that note. Undo puts your copy back, redraws it and saves it as a new version, then says "Undone. Your version is back, and saved."

If a build is running when the outside change arrives, the builder waits for the run to finish before redrawing, so a canvas is never swapped mid-build. If the builder was closed while the change happened, reopening the project shows the newer version straight away, with the same note and Undo.

How your own edits are saved

Edits in the builder are sent to the server a moment after you stop, with the version number the builder last saw. The server applies the write only if the project is still at that version, in a single step, so there's no gap between checking and saving. A write based on an old version is refused with a conflict and the current copy of the project. The same rule applies to every route in: the builder, a PUT to the project's anticode.json, anticode push from the CLI, and the MCP server's tools.

What you see in each case
What happenedWhat the builder shows
An agent saved while you weren't editingThe agent's version, with "Updated from outside Anticode" and Undo
You and an agent saved at nearly the same moment, and theirs landed firstTheir version, with "Someone else saved first, so your last change wasn't kept. This is their version." Undo brings yours back
An agent edited CMS entries shown on the pageThe bound sections refresh with the new entries; the project itself didn't change
The CLI's push hit a newer versionNothing in the builder. The CLI refuses and asks you to pull again

App builds

For a model-written app, the project mostly records which build is on show. When the server points at a build this project has never seen, for example one started by an assistant over MCP or in another tab, the builder shows that build as the app and says "Updated from outside Anticode. Undo brings yours back." A server copy pointing at a build the builder already knows is treated as a late save from earlier, and the builder's own choice stands.

Undo and history work together

The note's Undo is the quick route for the change that just arrived. For anything older, recent saves are also kept in version history, up to your plan's number, labelled by where it came from (your edit, build agents, CLI or coding agent, AI assistant over MCP), so you can see which saves were the agent's and restore any of them. Reviewing what an agent did before publishing is covered in the workflow on reviewing AI agent website changes.

Limits

  • Signed in only. A preview build that isn't saved to an account has no server copy to sync with.
  • Not instant. Changes show on the next check, which is up to about fifteen seconds, or sooner when you click back into the window.
  • Whole versions, not merges. When two edits collide, one version is shown and the other is one Undo away. The builder doesn't merge the two automatically.
  • Visible tabs only. A builder tab in the background doesn't check; it catches up when you return to it.

Questions people ask

Do I need to reload the builder after my agent edits the project?

No. The open builder checks for changes on its own and redraws when it finds one.

Could an agent overwrite something I just typed?

Not silently. Each write names the version it started from. If you saved first, the agent's write is refused with a conflict and the current copy to work from.

Does the redraw run the checks again?

Yes. The page is rebuilt from the new version and the Critic and Sentinel checks run on it, so the report matches the canvas.