Trendeall — e-commerce platform trendeall.com →
A retail client's online store, built from scratch on Next.js 16 and Payload 3, with Neon Postgres for data and Cloudflare R2 for media. I work across all of it: schema, checkout, caching, backups and the deploy path. HypeWalk, below, runs on the same platform.
The hard parts
- Checkout can't oversell. Stock is decremented with a conditional update inside the same transaction as the order, so two buyers racing for the last unit can't both win.
- Promo codes and receipt fingerprints are taken with
SELECT … FOR UPDATElocks, so a code can't be spent twice and a receipt can't be reused. - An outage traced to uncached catalogue reads: 5 GB of egress in 12 days. Fixed with a tag-invalidated cache and ISR, so an edit clears the pages it touches and nothing else.
- Nightly
pg_dumpbackups, AES-256 encrypted, and restore-tested into a throwaway Postgres. A backup that has never been restored is a hope. - Dependency audit findings taken from 27 to 0, and about 340 Vitest cases.
- Next.js 16
- Payload 3
- TypeScript
- PostgreSQL
- Neon
- Cloudflare R2
- Vitest
- pnpm
- Vercel