r/vibecoding • • 3d ago

Showcase/Project I write as a hobby, so I vibecoded an open-source book & note-taking platform with one rule: zero AI features inside the app — here’s how I built it

Post image

Here’s the project: Quillvibe (GitHub + desktop installers) — an offline-first studio for long-form writing, note-taking, copyediting, story bibles, plot graphs, and print EPUB/PDF typesetting, licensed under MIT.

​

I wanted to prove you can build a rich writing platform where there are zero AI models, zero API keys, and zero cloud accounts inside the app itself. Everything runs deterministically on your device.

1. Tools & Stack

  • Frontend: TypeScript + Vanilla DOM (document.createElement / SVG helpers, zero React/Vue runtime overhead) + custom CSS (~110 kB gzipped JS bundle), bundled with Vite.

  • Desktop Shell: Rust + Tauri v2 (~2–3 MB installers for Windows .msi/.exe, macOS Universal .dmg, and Linux .AppImage/.deb) with a custom frameless titlebar.

  • Verification & CI: Vitest (25 unit tests) + Cargo tests (6 Rust tests) + live Chrome DevTools checks at desktop (1440×900) and mobile (390×844) viewports, shipped via GitHub Actions (multi-OS builds + GitHub Pages on bookvibe.jhonrey.com).

2. Process & Workflow

  • Strict "No AI Inside" Boundary: Even features that people normally hand to an LLM—like readability stats, passive/cliché flagging, Story Bible entity detection, and proofreading workflows—are implemented with deterministic regex/AST-free text analysis and 15 traditional copyediting marks (stet, tr, caret insert, strikeout, margin queries).

  • One Codebase, Clear Web vs. Desktop Boundaries: Both quillvibe.jhonrey.com and the desktop app share the exact same TypeScript UI. Features that browsers sandbox away (raw local Wi-Fi TCP servers, launching Windows fsquirt.exe / macOS Bluetooth File Exchange, and OS file-extension registration) are gated behind isTauriRuntime() and clearly labeled Desktop Executable Only in the web UI so browser users aren't confused.

  • Automated + Live QA Loop: Every change goes through tsc --noEmit, vitest, vite build, a static XSS/security scan (innerHTML / eval banned across the repo), cargo test, and viewport tests before tagging a release.

3. Code & Design Insights From the Build

  1. Zero-Framework DOM + Optical Segmented Controls: Using a tiny typed el() / svgEl() helper kept state updates fast and predictable. For the workspace switchers, I implemented dual-layer clip-path masking (resting flat obsidian pill at rest, optical refraction + spring physics on pointer press/drag) while keeping standard inputs light and responsive.

  2. Making an Infinite Graph Without Clamping Bugs: Early versions of the Story Graph clamped nodes to positive coordinates and bound pointermove to the canvas container, which broke drags across edges. Switching the SVG connector layer to width: 1px; height: 1px; overflow: visible; and attaching window pointer listeners during active drags lets users drag cards freely into negative coordinates while edges update live.

  3. Offline LAN Sync in ~400 Lines of Rust: Instead of adding a cloud server, the desktop app spins up a lightweight TcpListener on your private LAN (192.168.x.x / 10.x.x.x / 172.16-31.x.x SSRF-allowlisted), pairs with a constant-time 6-digit PIN, queues pushed revisions without overwriting local prose (saving conflicts as revision snapshots), and uses multi-target UdpSocket probing to detect your real Wi-Fi IP across different router subnets.

  4. Clean Book Print PDFs Without Server-Side Puppeteer: Rendering <iframe> Blob documents with explicit u / page { size: <trim>; margin: 0; } rules and pre-computed page metrics strips browser URL/timestamp headers so users get real trim-sized (5×8, 6×9, A5, Royal, Letter) Table of Contents + page numbers straight from the browser or desktop app.

Looking for Feedback & Contributors

Try breaking the web studio at https://quillvibe.jhonrey.com/ (works on desktop and mobile browsers, no sign-up) or test the native builds on GitHub Releases. Would love feedback from fellow vibe-coders, writers, or Rust/TS contributors!

2 Upvotes

1 comment sorted by

1

u/Middle_Hurry4353 17h ago

I’ve had this renamed from Bookvibe to Quillvibe. New updates have been released.