Notes from projects I've worked on.
What broke on my Next.js, Node.js and Postgres projects, and how I fixed it.
- 01
Deploying Next.js and NestJS to AWS EC2 with Docker Compose
How I deploy a pnpm monorepo to one EC2 box. Images get built in GitHub Actions and Docker Compose pulls them from GHCR. The server has no code.
- 02
How I store OAuth tokens for social media APIs in NestJS
OAuth for Facebook, TikTok and YouTube in a NestJS API. State and PKCE, encrypted tokens, refreshing before each publish, and when to ask for a reconnect.
- 03
llms.txt on my Next.js site, and now Lighthouse grades it
vennee.dev has a hand-written llms.txt and an llms-full.txt built from the blog. Notes on the spec, .txt routes in Next.js, and Lighthouse 13's new audit.
- 04
PageSpeed gave my site 25 on mobile. My own Lighthouse said 90+
My own Lighthouse gave vennee.dev 90+. PageSpeed mobile said 25. A loader hid the LCP, Lighthouse simulated a slow network, and WebGL ran on the CPU.
- 05
Scheduled jobs in Node.js with pg-boss and NestJS
Publishing posts on time from a Postgres job queue: pg-boss in its own NestJS worker, queue policies, retries, jobs that run twice, and deploys.
- 06
What bit me doing S3 presigned URL uploads in NestJS
Presigned PUT or upload through the API, what the ticket signs, checking the object with HeadObject, and the env var that freezes every stored URL.
- 07
Where prisma migrate deploy should run in CI/CD
My Prisma migrate deploy step was committed and green, and production never ran it. Where migrations belong in CI/CD, and how to spot a lagging schema.
- 08
Building chat with Socket.IO and Next.js: bugs I hit in Sosifie
Text arrived instantly, images needed a reload, and typing showed in the chat but not the sidebar. Wiring Socket.IO, REST uploads and the client cache.
- 09
Firebase push notifications from Node.js to web and Expo
Sosifie's Node.js push notification setup, its single-device limit, and proposed fixes for FCM token cleanup, duplicate alerts and Expo support.
- 10
Fixing URLs, hreflang and sitemaps on my multilingual Next.js site
SEO mistakes I made on vennee.dev: a locale read from a cookie and hreflang aimed at a query string, plus metadata and a sitemap that didn't match.
- 11
Getting my Express TypeScript API ready for production
Sosifie's Express API in production: error handling, validation, express-rate-limit behind a proxy, helmet, Docker, and an if that stopped the server listening.
- 12
How I generate social posts with LangGraph in Node.js
Gemini in Sosifie's Node.js backend: a LangGraph loop that never looped, schema-constrained JSON, overlapping cron jobs and a crawler that had to move out.
- 13
How I keep a React Three Fiber scroll animation fast
How I kept scroll state outside React in vennee.dev's earlier 3D cube homepage, deferred the scene and reduced GPU work on phones.
- 14
How I run Playwright accessibility testing with axe-core
Automated a11y tests for a Next.js monorepo with axe-core and Playwright, including dark mode, a keyboard focus walk, legacy debt, and what axe can't see.
- 15
Keeping music playing across React routes with Redux Toolkit
Moving audio to the root of a Zing MP3 clone so routes can't stop it, then restoring the play position after a reload and splitting a hot selector.
- 16
Making GSAP ScrollTrigger wait for Next.js page transitions
ScrollTrigger measured too early on Viet Lasa Coffee. I made it wait for page transitions, then re-measure on filters and Sanity edits.
- 17
Moving a car rental site to Next.js without breaking URLs
Moving Sigo from a React SPA to Next.js and keeping two generations of URLs with next-intl, plus fixes for redirect status codes and param syntax.
- 18
Next.js cookies for auth when the API is on another domain
The API set a cookie, but Next.js couldn't see a session. How I handled domain scope, Route Handler cookies and logged-in local development.
- 19
One Express API for web and mobile, without two auth models
One Express API for Next.js and Expo. Cookies on the web and Bearer tokens on native, plus CORS for Expo web, Socket.IO auth and API versioning.
- 20
Permissions and paid-plan checks in the Next.js App Router
Notes from a B2B SaaS dashboard on one permission module, checks split between Next.js and the API, and what to update when a role or plan changes.
- 21
React Query, react-hook-form and Zod: updating data after a form save
Keeping server data apart from form drafts, consistent query keys, cache updates after a mutation, and API errors shown under the right form field.
- 22
Refresh tokens in the Next.js App Router when parallel requests return 401
httpOnly cookies, refreshing in the proxy before render, one shared refresh promise on the client, and the retry bugs I fixed one at a time.
- 23
Reverse infinite scroll in a React chat, minus the jump
Loading older chat messages upward in Sosifie: cursor pagination with Prisma, useInfiniteQuery, socket dedupe, and keeping scroll position steady.
- 24
Sharing web and mobile code with Next.js, Capacitor and Turborepo
Two Next.js apps in one monorepo: server rendering for the web, static export for Capacitor. What we could share and where I got stuck.
- 25
SSR, SSG and ISR in Next.js: what the build output tells you
How I tell static from dynamic App Router routes in the build output, separate data caching from page caching, and use revalidation in Next.js 15 and 16.
- 26
Updating CMS content in Next.js without rebuilding the site
How I connect CMS webhooks to revalidateTag and revalidatePath, and why a CDN or browser can still show old content after Next.js has refreshed.
- 27
Vietnamese search without diacritics in Postgres
Typing tuan doesn't find Tuấn with ILIKE, and NFD can't strip đ. Accent-insensitive search in Postgres with unaccent, pg_trgm and a folded column.
- 28
Why caching the menu hid my Next.js shop’s admin buttons
Public navigation and admin permissions shared one response. I cached its anonymous version on Ajuma Garden, and the shop owner lost the admin buttons too.
- 29
Writing Webflow code components in React, with Tailwind
Declaring props for designers, getting Tailwind into the Shadow DOM, then bundling and sharing a small React library as Webflow code components.