Skip to content

Drafts ​

A draft is a project before it becomes a repository, saved to your account as you work. Reach for /drafts when you want to reopen, switch, delete or restore one.

Quick start ​

Open code.extension.dev/drafts. Cloud drafts lists what your account holds, and each row opens at /drafts/<id>. The project switcher in the header offers New project, and a search box reading Find a project filters your drafts by name.

How it works ​

What syncs ​

Every change to the files is pushed to your account, and the terminal conversation is pushed with it, parked branches included. Open the same draft on another browser and the terminal resumes where it stopped. Chat mode's history travels inside the draft the same way.

Sync needs a sign-in. Signed out, the work stays in this browser only. If your session ends mid-work, a notice reads Your session expired with the time of the last saved edit and a Sign in and keep saving button.

The draft in this browser ​

The browser also keeps the open draft in the tab that made it. Each tab holds its own database, which sends a heartbeat every 10 seconds. A database whose heartbeat is 45 seconds old is swept on a later start. Closing the tab is not a save. The draft on your account is.

Three lists ​

SectionWhat it holds
Cloud draftsDrafts synced to your account, each with Delete
Recently deletedDeleted drafts and their conversations, kept 30 days, each with Restore
In this browserThe draft this browser has open right now

The project switcher ​

The control in the header that shows the project's slug opens the switcher. New project starts a fresh extension. A row that names the template the project is based on offers Start another project from the same template and opens /?template=<slug>. Find a project filters your other cloud drafts by name or slug.

Older addresses ​

Links of the shape /s/<id> still open and are rewritten to /drafts/<id> on the first render. The canonical address also carries the engine, such as /drafts/<id>/chromium.

Reference ​

LimitValue
Drafts per account100
Size of one draft4 MB
Files in one draft300
New drafts per UTC day300
Deleted drafts kept30 days
Tab heartbeatEvery 10 seconds
Tab database swept after a stale heartbeat of45 seconds

When it fails ​

  • A notice reads "Your account has no room for this draft". The account holds 100 drafts. Edits since the time shown are saved only in this browser. Delete drafts you no longer need from /drafts, then the next change saves again.
  • The server answers that the draft is too large. A draft holds 4 MB. Ask the agent to drop generated or binary files, or download the source and continue on your machine.
  • Too many new drafts today. The account created 300 drafts this UTC day. The notice names the minutes until the window opens again.
  • Work disappeared when you reopened the browser. The copy in this browser belongs to one tab and is swept once that tab is gone. Open the draft from /drafts, where your account keeps it.
  • A deleted draft is gone from Recently deleted. Deleted drafts are kept 30 days, then removed.

Next ​