Skip to content

About

marketing site for a family home-services business - single-file HTML + CF Pages function pulling live google reviews

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

iharthomes.com

marketing site for I Hart Homes, a family-owned home services company in Norman, OK. built as a single self-contained HTML file plus one serverless function, hosted on Cloudflare Pages. no build step, no framework, loads in one request.

live at iharthomes.com.

how it works

index.html                  the whole site - markup, styles, and js in one file
functions/api/reviews.js    cloudflare pages function: live google reviews
favicon.svg / *.png         HH logo mark favicons
logo*.png                   brand logo - full, mark-only, and transparent variants
og-image.png                social/imessage link preview card

live google reviews

the testimonials section isn't hardcoded - it renders the business's real google reviews at request time:

  • a pages function calls the places API (new) for the listing, filters to 4+ star reviews with text, and returns the top three plus the overall rating
  • responses cache 24h at the cloudflare edge, so google gets called a couple of times a day regardless of traffic. browsers cache 2 minutes, so fresh reviews and fixes propagate fast
  • the API key and place id live in pages secrets, never in the page
  • if the API is unreachable or unconfigured, the page keeps a static "read our reviews on google" card - it degrades to honest, never to fake

one hard-won detail: the listing is a service-area business (no storefront address), which makes it invisible to the legacy places API entirely. only the new API's includePureServiceAreaBusinesses search flag can find it.

quote form

plain html form posting to formspree (swap YOUR_FORM_ID in the action), with a honeypot field, client-side validation, and an async submit that falls back to "call us" if anything goes wrong - including when ad blockers block the request.

notes

  • design is intentionally local: handwritten accents, neighborhood names, and the interlocked HH logo mark
  • regular text in the page carries no fixed colors where possible so email/dark modes don't repaint it in odd ways
  • built and maintained with agentic tooling in the loop

About

marketing site for a family home-services business - single-file HTML + CF Pages function pulling live google reviews

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages