Versions and branches
Save a project or a screen, compare two states side by side, go back to any of them, and try another art direction on a branch.
A project changes under you: an edit, a polish, a new art direction. Versions let you keep a state on purpose, look at two states side by side, and go back to any of them. Branches let you try another direction on the same project without risking the one you had.
Open them with the Versions icon on the inspector's rail, on the right of a
project. A screen's own history is in its context menu: Versions of this screen.
Saving a version#
Type a name (optional) in the Versions panel and press Save. The version
holds every screen of the project — its code, its prompt, its pictures, its
links — and the project's art direction (DESIGN.md).
Why it works this way
Versions are kept on the server, not in the browser. The browser keeps the working copy in a space of about 5 MB that the screens' code already fills; ten copies of the project there would be the first thing to make saving fail. On the server, a code shared by two versions is written once, so a version of a project where one screen changed costs that one screen.
A screen can also be saved on its own, from Versions of this screen.
Automatic versions of a screen#
Why it works this way
A version taken by hand is a version taken when someone remembers to. After a few generations the history held the states a person had thought of saving and none of the others, which are usually the ones wanted back.
Every state a screen goes through is also saved on its own: when it is
created, then each time its code changes — an edit, a polish, a regeneration,
added animations, a repair. The version is taken once the screen has stopped
changing for two seconds and no pass is running on it, so a screen still being
written is never kept half-done. They appear in the Versions panel as
Screen created or Change, with the screen's name, and can be compared and
restored like any other.
Under that title, each one says what changed, in words: the instruction of
an edit as you typed it, the element and the change of a targeted modification,
Quality pass (Polish), SEO and accessibility fixes, Fitted to the page,
Regenerated, Restored from…, Frames changed, the text of a text replaced
in place, the error an automatic repair fixed. A new screen's line is the
request it was made from, whole. Versions saved before this existed have none.
The history has a trail above it — the branch, then All versions, then
one screen. A screen's name in a row (screen “…”) narrows the list to that
screen: its own versions and every project version that holds it. The trail
says where the list stands; All versions in it goes back up.
A screen that was already there when the project opened is not saved on sight;
the first time it changes, the state it had is kept first, as Original state.
The 30 most recent automatic versions of each screen are kept, per branch; past that, the oldest is dropped as the newest comes in. A version you saved by hand, and every project version, is never dropped this way.
Comparing#
Tick a version in the history, then:
Compare with the current state— that version on one side, the canvas on the other;- tick a second one and
Compare these two versions.
The comparison window lists every screen of either side, marked changed, added, removed or unchanged, and shows the chosen one side by side, each at its own size. It also says when the art direction differs. Either side can be switched to another version from its list.
Going back#
Restore on a project version puts the whole project back as it was: screens,
art direction, pinned reference screen.
Why it works this way
Before anything is replaced, the current state is saved as an automatic save on its branch. If that save fails — no network, a full disk — nothing is restored. Going back must never cost the state you were in.
The project's name is not restored: it is what you call the work, not a state of it. Restoring a version saved on another branch puts the project on that branch.
Restore this screen, from the comparison or a screen's history, brings back
that one screen and nothing else. It keeps where the screen sits on the canvas
and the notes written on it since. The ordinary Revert on the screen undoes
it, like it undoes an edit. A screen deleted since comes back as a new screen.
Keeping both#
Keep beside, from the comparison or a screen's history, restores nothing: it
adds that version of the screen to the canvas, right of the current one,
named after the version (Home — Light). Both stay, both work, and you compare
them whenever you like — the usual way to weigh two art directions, or a branch
against the main one, before choosing.
The copy is made like Duplicate: without the links, the notes or the route of
the original, so the demo never has two screens answering to the same page.
Branches#
A branch is another line of versions of the same project. The usual case:
The current direction is fine, and you want to try a darker oneDone
Create a branch named "Dark direction" from the
Versionspanel.Change what you like on itDone
Edit the DESIGN.md, regenerate, polish. Save versions along the way.
Go back to the main branchDone
with
Open. The project returns to its main direction; the dark one stays on its branch.Open the dark branch againDone
whenever you want. Delete it when you have chosen.
Switching branch saves the current state on the branch you leave, then opens the newest version of the other one. A branch exists as long as it has versions; the main one always exists. The branch you are on cannot be deleted — switch first.
What a version costs#
| Model calls | None. Saving, comparing, restoring and switching never call a model. |
| Disk | The server's, counted in the instance's storage limit (MOCKY_MAX_STORAGE_MB). Identical code is stored once. |
| Limits | 200 versions per project, 1,500 per account, 80 screens per version. Automatic screen versions make their own room (the oldest goes); for the others, delete old versions from the history. |
Deleting an account deletes its versions.
Thanks for your feedback!