All Project Templates

Cranium

by Yard
Cranium preview
Gallery image 0
Gallery image 1
Gallery image 2

Shared documents you write in together. Create a workspace, send its invite link, and everyone edits the same document at once, each with their own named cursor and no merge conflicts. The editor works like Google Docs, and every document stays plain Markdown. It ships with sign-in, a database, realtime documents, and a polished landing page, all running on Yard.

Features

  • Write together live: edits appear as people type, with a colored, named cursor and selection for each person and avatars showing who's in the document
  • No merge conflicts: two people can type in the same paragraph at once and both edits survive
  • Workspaces with one invite link: everyone gets a personal workspace on their first visit and can create more. Anyone who opens the invite link joins
  • Owner controls: only the owner sees the invite link, resets it, removes members, or deletes the workspace. Removing someone closes their open documents right away and resets the invite link by default, so they can't walk back in
  • A familiar editor: a menu bar, a toolbar with a text style picker, and Google Docs keyboard shortcuts
  • Markdown all the way through: headings, bold, italic, strikethrough, code, links, bulleted and numbered lists, checklists, quotes, code blocks, and horizontal lines. Markdown typed or pasted as text turns into formatting
  • Import, download, and source view: save any document as a .md file, import one at the cursor, or edit the raw Markdown. Leaving the source view applies only what you changed, so collaborators' edits elsewhere survive
  • Titles that write themselves: a document's first line is its title until someone renames it, and a rename reaches everyone like any other edit
  • Document grid: every document in a workspace as a card with its title, a preview, its author, and when it was last edited. Sort by last edited, created, or title
  • Edits survive a dropped connection: keep typing through a network blip. On reconnect the document catches up on what you missed and sends what you wrote
  • Word count: words and characters for the whole document or just the selection
  • Light and dark themes that follow your system, with a toggle to override it

Built on Yard

  • Yard Auth: people sign in with their Yard account. Cranium never handles a password, and after the first consent screen, sign-in is silent
  • Hosted service: the entire backend is a single fetch handler with no server to run or scale
  • Objects: each document is its own realtime room that holds its connections and its content. An open document costs no compute while nobody is typing
  • Database: people, workspaces, members, and the document list live in the project's own SQLite database, and schema migrations apply themselves on deploy
  • Pricing: a single free tier, so signing in is the only gate. Add a paid tier to start charging

Technical details

  • Plain HTML, CSS, and JavaScript with no build step. The TipTap editor and Yjs ship prebuilt as one committed module, so the repository deploys as it is
  • The merging happens in the browsers, which use Yjs, a CRDT library. The server never reads an edit's contents: it numbers, stores, and relays each update, so the backend stays one plain module with no dependencies
  • A reconnecting tab downloads only the updates it missed and resends anything that never arrived
  • Browsers compact each document's history: once the log grows, the room asks a connected tab for a snapshot, which keeps storage close to the document's real size
  • Typing is batched every 80 ms and cursor moves are throttled, which keeps metered object usage low
  • Titles and previews are written to the database at most once every 5 seconds per document, not on every keystroke

Requirements

A Pro plan, for the hosted service, database, objects, and custom landing page. Yard Auth is included.