/* ============================================================= * App router — hash-based, code-split-ready * ============================================================= */ // SEO: per-route page title & meta description. // Browser tab + Google search snippet update as users navigate. const PAGE_SEO = { home: { title: "Fathers Arise — Restoring Fatherhood. Building Nations.", description: "Every generation needs fathers who stay. Join the movement restoring men to their God-given role across Uganda." }, about: { title: "About — Fathers Arise", description: "Who we are. Pastor Isaac Mukisa and the Fathers Arise team — building men the world is waiting for, from boyhood to fatherhood to legacy." }, "be-a-man": { title: "Be A Man — Fathers Arise", description: "Raising a generation of men who know who they are before the world tells them who to be. Schools, universities, and prisons across Uganda." }, "nurturing-bonds": { title: "Nurturing Bonds — Fathers Arise", description: "Seven programs equipping fathers to be emotionally present, spiritually grounded, and intentionally connected to their families." }, "mobile-kanaabe": { title: "Mobile Kanaabe — Fathers Arise", description: "Economic empowerment for young men who need more than words — they need work. Skills training and micro-enterprise." }, forge: { title: "The Forge — Fathers Arise", description: "Forge groups across Uganda — communities of fathers committed to staying present, honest, and in their children's lives." }, "champion-virtues": { title: "Champion Virtues — Fathers Arise", description: "The 6-pack code. Six commitments. One man. The moral code of every man in the Fathers Arise movement." }, stories: { title: "Stories — Fathers Arise", description: "Every man in Fathers Arise carries a story. Stories of transformation, healing, and becoming." }, events: { title: "Events — Fathers Arise", description: "Upcoming Forge gatherings, Be A Man sessions, and community events. Join us in person." }, donate: { title: "Donate — Fathers Arise", description: "Your gift puts one father in a Forge group. Mobile Money for Uganda, international cards worldwide. Secure payments." }, "get-involved": { title: "Get Involved — Fathers Arise", description: "Register, volunteer, partner, or give. There is a place for you in the movement." }, contact: { title: "Contact — Fathers Arise", description: "Get in touch. A real person will reply. WhatsApp is fastest." }, "team-login": { title: "Team Login — Fathers Arise", description: "Internal OS for Fathers Arise leadership." } }; function _applyPageSEO(routeKey) { const seo = PAGE_SEO[routeKey] || PAGE_SEO.home; document.title = seo.title; let m = document.querySelector('meta[name="description"]'); if (m) m.setAttribute("content", seo.description); // Also update OG title/desc so freshly-shared links show the right preview const ogTitle = document.querySelector('meta[property="og:title"]'); if (ogTitle) ogTitle.setAttribute("content", seo.title); const ogDesc = document.querySelector('meta[property="og:description"]'); if (ogDesc) ogDesc.setAttribute("content", seo.description); // Canonical URL let canonical = document.querySelector('link[rel="canonical"]'); if (canonical) { canonical.setAttribute("href", "https://fathersarize.org/" + (routeKey === "home" ? "" : "#/" + routeKey)); } } function App() { const [route] = useHashRoute(); // Update title + meta on every route change for SEO + browser tab clarity useEffect(() => { _applyPageSEO(route); }, [route]); let page; switch (route) { case "home": page = ; break; case "about": page = ; break; case "be-a-man": page = ; break; case "nurturing-bonds": page = ; break; case "mobile-kanaabe": page = ; break; case "forge": page = ; break; case "champion-virtues": page = ; break; case "stories": page = ; break; case "events": page = ; break; case "donate": page = ; break; case "get-involved": page = ; break; case "contact": page = ; break; case "team-login": page = ; break; default: page = ; } return (
{page}
); } const root = ReactDOM.createRoot(document.getElementById("root")); root.render();