Monorepo for the Dividir landing site and mobile-first expense splitting app.
Built with pnpm workspaces, React, Vite, Tailwind CSS, TanStack Router, Convex, Convex Auth, Dexie, and vite-plugin-pwa.
Dividir is a Splitwise-style app focused on small groups like trips, dinners, and shared plans. The repo now has two independently deployable sites:
apps/landing: static marketing site forhttps://dividir.appapps/app: authenticated PWA forhttps://go.dividir.app
The app is designed as a mobile-first progressive web app with offline-friendly behavior, Spanish-first copy, and a fast local dev flow.
Current app scope includes:
- Email magic link, Google, and local dev login flows through Convex Auth
- Group list, group detail, add expense, settle up, and group settings screens
- Balance tracking with exact minor-unit money math
- Offline caching and queued mutations with Dexie
- PWA install support and service worker updates
- Demo data visible after local dev login, including groups like
Viaje a Ibiza 2024
- pnpm workspaces
- React 19
- Vite
- TanStack Router
- Convex
- Convex Auth
- Tailwind CSS v4
- Dexie
- vite-plugin-pwa
pnpm installCopy the frontend env file:
cp .env.example .env.localCopy the Convex deployment env file:
cp .env.convex.example .env.convexFrontend app env in .env.local:
VITE_CONVEX_URL=
CONVEX_DEPLOYMENT=
VITE_CONVEX_SITE_URL=
VITE_DEV_LOGIN_ENABLED=trueConvex deployment env in .env.convex:
AUTH_SECRET=
SITE_URL=
JWT_PRIVATE_KEY=
JWKS=
AUTH_GOOGLE_ID=
AUTH_GOOGLE_SECRET=
AUTH_RESEND_KEY=
PUSH_VAPID_PUBLIC_KEY=
PUSH_VAPID_PRIVATE_KEY=
PUSH_VAPID_SUBJECT=VITE_DEV_LOGIN_ENABLED=true enables the one-click local login button labeled Entrar como LLM Agent.
Run the backend in one terminal:
pnpm convex:devIf you change backend auth code or Convex functions, keep this process running so generated files and local backend state stay in sync.
Run the app in another terminal:
pnpm dev:appOpen the local URL printed by Vite, usually http://localhost:5175/.
On the login screen:
- Click
Entrar como LLM Agent - Confirm the app redirects to
/groups - Confirm the dashboard loads demo groups such as
Viaje a Ibiza 2024
If .env.local is missing or VITE_CONVEX_URL is not configured, the app can still boot in mock mode so you can inspect the shell and styling. The full authenticated flow, live data, and synced mutations require Convex.
Create two Vercel projects from this repo:
- Landing project: set Root Directory to
apps/landing, attachdividir.app. - App project: set Root Directory to
apps/app, attachgo.dividir.app.
Each project has its own vercel.json. The app project keeps SPA rewrites for TanStack Router, while the landing project is a plain static Vite build.
pnpm dev:app
pnpm dev:landing
pnpm build
pnpm build:app
pnpm build:landing
pnpm lint
pnpm typecheck
pnpm preview:app
pnpm preview:landing
pnpm convex:dev
