import { MetaProvider, Title } from "@solidjs/meta";
import { Router } from "@solidjs/router";
import { FileRoutes } from "@solidjs/start/router";
import { Suspense } from "solid-js";
import { ThemeProvider } from "./lib/theme";
import { AppShell } from "./components/layout";
import { ToastProvider } from "./components/ui";
import "./app.css";

export default function App() {
  return (
    <ThemeProvider>
    <ToastProvider>
    <Router
      root={(props) => (
        <AppShell>
          <Suspense>{props.children}</Suspense>
        </AppShell>
      )}
    >
      <FileRoutes />
    </Router>
    </ToastProvider>
    </ThemeProvider>
  );
}
