diff --git a/client/index.html b/client/index.html index 0c589ec..891a938 100644 --- a/client/index.html +++ b/client/index.html @@ -8,6 +8,6 @@
- + diff --git a/client/src/App.jsx b/client/src/App.tsx similarity index 97% rename from client/src/App.jsx rename to client/src/App.tsx index 6f590f8..3a6f73a 100644 --- a/client/src/App.jsx +++ b/client/src/App.tsx @@ -1,5 +1,3 @@ -/// - import { MetabaseProvider, InteractiveQuestion, diff --git a/client/src/env.d.ts b/client/src/env.d.ts new file mode 100644 index 0000000..e2baf9d --- /dev/null +++ b/client/src/env.d.ts @@ -0,0 +1,8 @@ +interface ImportMetaEnv { + readonly VITE_METABASE_INSTANCE_URL: string; + readonly CLIENT_PORT?: string; +} + +interface ImportMeta { + readonly env: ImportMetaEnv; +} diff --git a/client/src/main.jsx b/client/src/main.jsx deleted file mode 100644 index 637e43b..0000000 --- a/client/src/main.jsx +++ /dev/null @@ -1,9 +0,0 @@ -import { StrictMode } from "react"; -import { createRoot } from "react-dom/client"; -import App from "./App.jsx"; - -createRoot(document.getElementById("root")).render( - - - , -); diff --git a/client/src/main.tsx b/client/src/main.tsx new file mode 100644 index 0000000..0637053 --- /dev/null +++ b/client/src/main.tsx @@ -0,0 +1,15 @@ +import { StrictMode } from "react"; +import { createRoot } from "react-dom/client"; +import App from "./App"; + +const rootElement = document.getElementById("root"); + +if (!rootElement) { + throw new Error("Root element not found"); +} + +createRoot(rootElement).render( + + + , +);