Building the Portal
How I built a cinematic personal website with Astro, GSAP, and Cloudflare Pages — and why every animation should earn its place.
The idea
I wanted a personal site that felt like stepping into a creative studio — not another developer portfolio with a grid of cards and a “Hi, I’m…” hero.
The concept: two dark panels crack apart like vault doors, revealing a full-bleed image. Your name stretches across the viewport, tracking tightening as the panels open. Below, a deck of project sleeves you drag through like vinyl records.
The stack
Astro was the natural choice — static-first, ships zero JS by default, and the islands architecture means GSAP only loads where it’s needed.
GSAP handles the heavy lifting: the portal animation timeline, scroll-triggered parallax, and the draggable catalogue deck. For simpler interactions (card hovers, link underlines), plain CSS transitions do the job.
Tailwind CSS with custom design tokens keeps the styling consistent. Every color, spacing value, and border-radius comes from the declared system.
Cloudflare Pages for hosting — unlimited bandwidth on the free tier, 300+ edge locations, and deploys on every push.
The portal animation
The hero sequence is a single GSAP timeline with five stages:
- Wordmark fades in with wide letter-spacing
- Panels slide outward, tracking tightens simultaneously
- Hero image scales to 1× with parallax shift
- Name halves drift to opposite viewport edges
- Subtitle and scroll indicator fade in
The whole sequence takes about 3 seconds. Every easing curve is power3.inOut for that cinematic feel — no bouncy springs.
const tl = gsap.timeline({ defaults: { ease: 'power3.inOut' } });
tl.to([nameFirst, nameLast], { opacity: 1, duration: 0.8, stagger: 0.1 })
.to(panelLeft, { xPercent: -100, duration: 1.4 })
.to(panelRight, { xPercent: 100, duration: 1.4 }, '<')
.to([nameFirst, nameLast], { letterSpacing: '0.05em', duration: 1.4 }, '<');
Lessons learned
prefers-reduced-motionis not optional. Every animation has an instant fallback.- Ship zero JS where you can. Astro’s island architecture means most pages load no JavaScript at all.
- The portal animation is the portfolio piece. When the site itself demonstrates your craft, every page is a case study.