Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
8993a3e
refactor: extract overview page into custom hooks and card components
hasnaintypes Mar 17, 2026
675a19c
perf: add React.memo, useCallback, and Suspense across client components
hasnaintypes Mar 17, 2026
ee9f456
perf: optimize backend with DB aggregations, N+1 fix, and worker reli…
hasnaintypes Mar 17, 2026
34e4fee
docs: clear completed GAP.md and add folder structure refactor plan
hasnaintypes Mar 17, 2026
78a9e35
refactor: reorganize folder structure, add SMTP fallback, and upgrade…
hasnaintypes Mar 17, 2026
b82e39b
fix: upgrade Next.js to 15.5.9 and React to 19.2.4
hasnaintypes Mar 18, 2026
0beecc0
security: harden input validation, CSP header, and report resend
hasnaintypes Mar 18, 2026
0f41d20
refactor: remove Zustand store in favor of React Query
hasnaintypes Mar 18, 2026
aa6880b
fix: add error boundaries and fix useIsMobile hydration mismatch
hasnaintypes Mar 18, 2026
4d05b52
perf: add database indexes and constraints
hasnaintypes Mar 18, 2026
07e0dd1
ci: fix pnpm version and add build step
hasnaintypes Mar 18, 2026
edf1acf
feat: implement transaction alert email pipeline
hasnaintypes Mar 18, 2026
a014a6c
chore: update .gitignore and remove obsolete documentation files
hasnaintypes Mar 18, 2026
412ae5e
fix(email): add compileTemplate helper, email validation, template wh…
hasnaintypes Mar 18, 2026
7d87d71
fix(security): add category ownership validation, open redirect guard…
hasnaintypes Mar 18, 2026
e2212b3
fix(inngest): add Zod event validation, NonRetriableError, Handlebars…
hasnaintypes Mar 18, 2026
9e5acd5
fix(ai): strip raw response from errors, add date filter to anomalies…
hasnaintypes Mar 18, 2026
dc206b3
fix(routers): move ownership checks into WHERE clause for account and…
hasnaintypes Mar 18, 2026
33eaa49
perf(budget): fix N+1 in evaluateBudgets and add ownership check to c…
hasnaintypes Mar 18, 2026
554af6b
fix(build): add force-dynamic to AI API routes to prevent Prisma erro…
hasnaintypes Mar 18, 2026
1d62bbb
fix: resolve client-side env access in error page and Decimal seriali…
hasnaintypes Mar 18, 2026
68b520e
fix(logging): use process.env.NODE_ENV instead of T3 env for client c…
hasnaintypes Mar 18, 2026
68094bc
fix(db): lazy-initialize PrismaClient to prevent build failures in CI
hasnaintypes Mar 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 50 additions & 29 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -10,48 +10,69 @@
# When adding additional environment variables, the schema in "/src/env.js"
# should be updated accordingly.

# App URL
NEXT_PUBLIC_APP_URL="http://localhost:3000"

# Node environment
# ──────────────────────────────────────────────
# Core
# ──────────────────────────────────────────────
NODE_ENV="development"
NEXT_PUBLIC_APP_URL="http://localhost:3000"

# Database
# ──────────────────────────────────────────────
# Database (PostgreSQL)
# ──────────────────────────────────────────────
DATABASE_URL="postgresql://postgres:password@localhost:5432/trackit-saas"
# Optional: Prisma Accelerate service URL (leave empty if not using Prisma Accelerate)
PRISMA_ACCELERATE_URL=""

# Better Auth
# ──────────────────────────────────────────────
# Authentication (Better Auth)
# ──────────────────────────────────────────────
BETTER_AUTH_SECRET="your_secret_here"
BETTER_AUTH_URL="http://localhost:3000"

# Inngest (async jobs & schedules)
# ──────────────────────────────────────────────
# Email - Primary: Resend (optional, needs paid plan)
# ──────────────────────────────────────────────
RESEND_API_KEY="your_resend_api_key"
EMAIL_FROM="noreply@yourdomain.com"

# ──────────────────────────────────────────────
# Email - Fallback: SMTP (e.g. Gmail, Mailtrap)
# ──────────────────────────────────────────────
SMTP_HOST="smtp.gmail.com"
SMTP_PORT=587
SMTP_USER="you@gmail.com"
SMTP_PASS="your_app_password"
SMTP_FROM="Trackit <you@gmail.com>"

# ──────────────────────────────────────────────
# AI (Google Gemini) — server-side only
# ──────────────────────────────────────────────
GEMINI_API_KEY="your_gemini_api_key"
GEMINI_MODEL="gemini-2.5-flash"
GEMINI_MAX_ROWS=50
# Client-side row limit (for bulk import UI validation)
NEXT_PUBLIC_GEMINI_MAX_ROWS=50

# ──────────────────────────────────────────────
# Background Jobs (Inngest) — optional
# ──────────────────────────────────────────────
INNGEST_EVENT_KEY="your_inngest_event_key"
INNGEST_SIGNING_KEY="your_inngest_signing_key"

# Better Stack Logging
NEXT_PUBLIC_BETTER_STACK_SOURCE_TOKEN=<token>
NEXT_PUBLIC_BETTER_STACK_INGESTING_URL=<url>
NEXT_PUBLIC_BETTER_STACK_LOG_LEVEL=debug

# ImageKit.io for image uploads
# ──────────────────────────────────────────────
# Image Uploads (ImageKit) — optional
# ──────────────────────────────────────────────
IMAGEKIT_PRIVATE_KEY="your_imagekit_private_key"
IMAGEKIT_URL_ENDPOINT="https://ik.imagekit.io/your_imagekit_id"
NEXT_PUBLIC_IMAGEKIT_PUBLIC_KEY="your_imagekit_public_key"
NEXT_PUBLIC_IMAGEKIT_URL_ENDPOINT="https://ik.imagekit.io/your_imagekit_id"

# RESEND API for transactional emails
RESEND_API_KEY="your_resend_api_key"
EMAIL_FROM="your@email.com"

# Gemini AI Service
GEMINI_MAX_ROWS=50
GEMINI_API_KEY='your_gemini_api_key'
GEMINI_MODEL='gemini-2.5-flash'
NEXT_PUBLIC_GEMINI_API_KEY='your_gemini_api_key'
NEXT_PUBLIC_GEMINI_MODEL='gemini-2.5-flash'
NEXT_PUBLIC_GEMINI_MAX_ROWS=50
# ──────────────────────────────────────────────
# Logging (Better Stack / Logtail)
# ──────────────────────────────────────────────
NEXT_PUBLIC_BETTER_STACK_SOURCE_TOKEN="your_source_token"
NEXT_PUBLIC_BETTER_STACK_INGESTING_URL="https://in.logs.betterstack.com"
NEXT_PUBLIC_BETTER_STACK_LOG_LEVEL="debug"

# Upstash Redis for rate limiting and caching
# ──────────────────────────────────────────────
# Rate Limiting (Upstash Redis) — optional
# ──────────────────────────────────────────────
UPSTASH_REDIS_REST_URL="your_upstash_redis_rest_url"
UPSTASH_REDIS_REST_TOKEN="your_upstash_redis_rest_token"
UPSTASH_REDIS_REST_TOKEN="your_upstash_redis_rest_token"
9 changes: 7 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: 10
version: 10.15.0

- name: Cache pnpm store
uses: actions/cache@v4
Expand All @@ -58,5 +58,10 @@ jobs:
- name: Type check
run: pnpm run typecheck

- name: Run Format check
- name: Run Format check
run: pnpm run format:check

- name: Build
env:
SKIP_ENV_VALIDATION: 'true'
run: pnpm run build
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,5 @@ yarn-error.log*
test-results/
playwright-report/
CLAUDE.md
.claude/
.claude/
.planning/
Loading
Loading