Note Calc is a collaborative Python notepad + calculator built for fast technical thinking.
It combines a code editor, inline computation, and real-time sharing in a single web app.
Most tools force a tradeoff between "note-taking" and "calculation". Note Calc is built to do both:
- Write plain-English context and Python logic in one place
- Execute and inspect outputs without leaving the editor
- Share, review, and iterate with collaborators in real time
- Guest mode on
/with an instant demo note (no login required) - Python execution in-browser via Pyodide
- Inline line-level calculation results
- Authenticated note persistence in Supabase
- Auto-save workflow for authenticated notes
- Rich note metadata (tags, pin, important flag, related date)
- Smart note discovery (filtering, sorting, and search ranking)
- Real-time collaborative editing + live collaborator presence
- Share controls:
- private notes
- link-based read access
- link-based edit access
- email-based read/edit access
- Role-aware access model (
owner,shared_read,shared_edit,public_read,public_edit)
- Unit/integration test suite with Vitest + Testing Library for core modules:
- auth flows and redirect safety
- notes/profile API adapters and hooks
- editor preferences store
- collaboration session behavior
- Pyodide runner/intellisense integration points
- Browser-level Playwright coverage for notepad guest workflows:
/notepadloads editor shell and key controls- guest draft persistence behavior in local storage
- CI workflow in
.github/workflows/ci.ymlenforces:- lint
- coverage tests
- production build
- notepad browser tests
/guest editor + app entry/loginemail OTP and optional OAuth sign-in/auth/callbackauth token/code exchange/notepad/:noteIdowned or shared note by ID/shared/:shareTokentoken-based shared note access/aboutproduct overview
- Frontend: React 19, TypeScript, Vite
- Routing/Data: TanStack Router, TanStack Query
- UI: Mantine
- Editor: Monaco
- Python runtime: Pyodide (web worker)
- Collaboration: Yjs + Supabase Realtime channel sync
- Backend: Supabase (Postgres, Auth, RLS, RPC)
- Deploy target: Cloudflare Pages
Supabase migrations in supabase/migrations/ define:
notesandnote_sharestables- row-level security (RLS) policies for owner/shared/public access
- RPC-based access functions for:
- guest draft import
- listing accessible notes
- secure note reads by ID or share token
- secure note updates with permission checks
- share management and public access control
- Node.js 20+
pnpm- A Supabase project
pnpm installCreate a local .env (or copy from .env.example) and set:
VITE_SUPABASE_URL=...
VITE_SUPABASE_ANON_KEY=...
VITE_SUPABASE_OAUTH_PROVIDERS=google,github # optional, comma-separatedRun SQL files in supabase/migrations/ in chronological order:
20260210_notes_backend.sql20260213_fix_note_shares_rls_recursion.sql20260214_allow_anon_link_edit.sql20260217_optimize_rls_and_fk_indexes.sql
In Supabase Auth URL settings:
- Local site URL:
http://localhost:5173 - Local redirect URL:
http://localhost:5173/auth/callback - Production site URL: your deployed domain
- Production redirect URL:
https://<your-domain>/auth/callback
pnpm devInstall Playwright browser binaries:
pnpm exec playwright install chromiumOn Linux CI/containers, install system dependencies when needed:
pnpm exec playwright install --with-deps chromiumpnpm devstart local dev serverpnpm buildtype-check + production buildpnpm lintrun ESLintpnpm testrun unit/integration testspnpm test:watchrun tests in watch modepnpm test:coveragerun tests with coverage reports (coverage/)pnpm test:e2erun browser tests for notepad flows (Playwright)pnpm test:e2e:headedrun browser tests with visible browserpnpm checkrun lint + coverage + production buildpnpm previewpreview production build locallypnpm pages:deploybuild and deploy to Cloudflare Pages via Wrangler
- Ensure
VITE_SUPABASE_URLandVITE_SUPABASE_ANON_KEYare set in Pages environment variables - Keep SPA fallback enabled so routes like
/notepad/:idand/shared/:tokenresolve toindex.html - Keep Supabase redirect URLs in sync with deployed domains
This repository is licensed under the Note Calc Non-Commercial License v1.0 (LICENSE).
- Non-commercial use, modification, and redistribution are allowed
- Commercial/profit-generating use requires explicit written permission from the copyright holder