import React, { lazy, Suspense } from "react";
import { createRoot } from "react-dom/client";
import useLocation from "wouter/use-location";
import { normalise } from "./util";
import Container from "./components/Container";
const Home = lazy(() => import("./pages/main/Home"));
const Exp = lazy(() => import("./pages/main/Exp"));
const Work = lazy(() => import("./pages/main/Work"));
const Contact = lazy(() => import("./pages/main/Contact"));
const NotFound = lazy(() => import("./pages/main/404"));
function App() {
const [location, navigate] = useLocation();
const normalised = normalise(location);
if (location !== normalised) {
navigate(normalised, { replace: true });
return null;
}
if (normalised === "/") return ;
if (normalised === "/experience") return ;
if (normalised.startsWith("/experience/")) return ;
if (normalised === "/work") return ;
if (normalised === "/contact") return ;
// if (normalised === "/live") return ;
// if (normalised === "/blog") return ;
// if (location.startsWith("/blog")) return ;
return ;
}
createRoot(document.getElementById("root")!).render(
,
);