God's Own Guide
God's Own Guide
Offline-capable Kerala travel guide and itinerary builder built with Astro, React islands, Leaflet, and Supabase.

Destination guide and trip planner covering all 14 districts of Kerala. Built with Astro for fast static delivery and hydrated React islands for interactive Leaflet maps, drag-and-drop itinerary ordering (@dnd-kit), PDF trip export (html2pdf.js), and service-worker offline caching via Vite PWA.


Unreliable connectivity on hill & backwater routes
Travelers exploring high-range hill stations and backwater routes in Kerala frequently lose mobile data connectivity, making heavy client-rendered travel sites and online-only maps unreliable mid-trip.

Astro static speed + offline PWA itinerary planner
Combined Astro static generation with selective React islands, Vite PWA service-worker caching, and Supabase for saved user itineraries and destination reviews. Added @dnd-kit day-by-day trip sorting and client-side PDF export so travelers can carry offline copies of their routes.

Interactive Leaflet Maps & Offline PWA
System Core · Role-Based Access Control with Supabase
import React, { useEffect, useState } from 'react';
import { supabase } from '../../lib/supabase';
const AdminGuard = ({ children }) => {
const [authorized, setAuthorized] = useState(false);
useEffect(() => {
const checkAuth = async () => {
const { data: { session } } = await supabase.auth.getSession();
if (!session) {
window.location.href = '/'; // Redirect unauthenticated users
return;
}
const { data: profile } = await supabase
.from('profiles')
.select('role')
.eq('id', session.user.id)
.single();
if (profile?.role === 'admin') {
setAuthorized(true);
} else {
window.location.href = '/'; // Redirect non-admin users
}
};
checkAuth();
}, []);
if (!authorized) return null; // Or show a loading/unauthorized message
return <>{children}</>;
};
export default AdminGuard;
Next Case Study