Personal portfolio site for Michael Read.
This document is the maintenance guide for future updates so you can quickly change content, visuals, and link previews without breaking deployment.
- Frontend: React + Vite + Tailwind CSS
- Package manager:
pnpmvia Corepack - Source app root:
client/ - Static Pages output:
dist/public
Important paths:
- App HTML template:
client/index.html - Main content data:
client/src/data/siteContent.ts - Global styles:
client/src/index.css - Required public assets:
client/public/assets/ - Pages workflow:
.github/workflows/deploy-pages.yml
Install dependencies:
corepack pnpm install --frozen-lockfileRun locally:
corepack pnpm devLocal preview of production build:
corepack pnpm build:pages
corepack pnpm preview --host 127.0.0.1 --port 4173Use this checklist whenever updating the site:
- Pull latest:
git checkout main
git pull --ff-only origin main- Make edits (content, styles, assets).
- Run validation:
corepack pnpm check
corepack pnpm build:pages- Smoke test local preview on desktop and mobile width.
- Commit and push:
git add -A
git commit -m "Your message"
git push origin main- Verify GitHub Actions deployment finished successfully.
Edit:
client/src/data/siteContent.ts
This file controls:
- Name, role, summary
- Social links
- Experience, education, certifications, projects
- Share metadata defaults (title/description/image URL)
Edit components under:
client/src/components/
High-impact files:
HeroSection.tsxExperienceSection.tsxPortfolioSection.tsxCertificationsSection.tsxContactSection.tsx
Edit:
client/src/index.css
Current design direction:
- Dark premium background
- Red-accent theme
- Glass-card style
Build will fail if these are missing:
client/public/assets/profile-photo.png
Validation script:
scripts/validate-required-assets.mjs
Current social preview image:
client/public/assets/og-preview-v4.jpg
Metadata source:
client/index.htmlindex.html(keep in sync to avoid stale previews from root-served contexts)client/src/data/siteContent.ts(shareTitle,shareDescription,shareImageUrl)
Ensure these exist in client/index.html:
canonicalog:title,og:description,og:type,og:url,og:site_nameog:image,og:image:secure_url,og:image:type,og:image:width,og:image:height,og:image:alttwitter:card=summary_large_imagetwitter:title,twitter:description,twitter:image,twitter:image:alt
Link previews are cached by messaging/social platforms. If old previews persist:
- Change image filename version (example:
og-preview-v5.jpg). - Update metadata URLs to the new filename.
- Rebuild and redeploy.
- Re-share the link (or append a temporary query parameter when testing).
For professional mobile text previews:
- Size:
1200x630 - Keep text minimal (headline + role only)
- Keep face centered with safe top headroom
- High contrast typography
- Avoid dense paragraphs or too many badges
Current approved style:
- Executive portrait on right
- Clean text block on left
- Minimal copy
Pages must use GitHub Actions deployment (not branch-root publishing).
Workflow:
.github/workflows/deploy-pages.yml
Build command:
corepack pnpm build:pages
Artifact path:
dist/public
dist/public/index.htmldist/public/404.htmldist/public/CNAMEdist/public/assets/profile-photo.pngdist/public/assets/og-preview-v4.jpg
If you see warnings from unresolved analytics placeholders, check index.html/client/index.html for raw %VITE_*% tags.
Preferred behavior:
- Only inject analytics script at runtime when env vars exist (already handled in app logic).
Check:
- GitHub Pages source is set to
GitHub Actions. - Latest workflow run succeeded.
CNAMEexists in built artifact.
- Test locally at mobile viewport before pushing.
- Re-check touch targets and spacing in affected section.
- Verify no section-specific background is fighting global background.
Use Playwright screenshots before commit:
corepack pnpm dlx playwright@1.51.1 screenshot --device="Desktop Chrome" --full-page http://127.0.0.1:4173/ .tmp-visual/desktop.png
corepack pnpm dlx playwright@1.51.1 screenshot --browser=chromium --viewport-size="393,852" --full-page http://127.0.0.1:4173/ .tmp-visual/mobile.pngNotes:
.tmp-visual/is local scratch; do not commit it.
- Keep changes scoped per task (content vs theme vs metadata).
- Use clear commit messages:
Refine contact form readabilityPolish OG preview and social metadata
# status
git status -sb
# latest commits
git log --oneline --decorate -n 5
# sync local to remote
git fetch origin --prune
git pull --ff-only origin main