Red Shop and Archive
Live portfolio and shop built to grow with the business, for an artist soon to start selling original paintings and prints. There are three site modes set in the admin panel: Portfolio (just a showcase, nothing for sale), Shop redirect (every shop link sends visitors to an external URL), and Full ecommerce (the complete in-site shop). Legal pages and shop-related features switch automatically with the chosen mode. There are multiple other features built to give the admin freedom in how they want to sell now and in the future.
TypeScript, Next.js 16 (App Router, Server Components), React 19, Node.js, PostgreSQL, Neon (serverless Postgres), Stripe (live account, Payment Intents, webhooks), custom JWT auth with bcryptjs and OTP email verification, Brevo (transactional email), Cloudinary (image hosting), postcodes.io (UK postcode and city validation), Netlify (serverless deployment, CI/CD), Cloudflare (domain, DNS), GitHub (version control, automatic deploys on push), GitHub Actions (scheduled cron for daily data-retention sweep), HTML5, CSS3, HTTPS/TLS, environment-based secret management
Customers browse and buy once the shop's switched on. Checkout reserves stock the moment it starts, not after payment, closing a race condition that could otherwise let two people buy the last unit of a one-of-a-kind piece at the same time. Guests verify their email with a one-time code before paying, and the postcode and city are checked against live UK data before an order goes through. Every form that collects data (contact, newsletter, registration, checkout) requires its own consent checkbox, checked on the server, not just the browser. Abandoned sign-ups delete themselves after 48 hours, unsubscribing from the newsletter is one click. Old orders past the 6-year retention period are anonymised automatically by a daily scheduled job. Dormant accounts with no order history are deleted after 2 years, accounts with real order history can be deleted manually by owner. The admin section has options: shop and archive content, products and stock, legal pages (update automatically with the site's mode; for full ecommerce changing legal pages has its own secondary switch), registration, contact form, newsletter, and business information (cascading-off fields depending on site mode) from one panel with no code changes needed. Built with GDPR-compliant data handling: a full privacy notice, consent capture at every point data is collected, self-serve password reset and account deletion. Deployed serverlessly on Netlify with a Neon Postgres database.
