Skip to content

A full-featured CRM built with React, shadcn/ui, and Supabase.

introduce a script.tsx to be used in html and index.tsx to serve of entrypoitn to the lib

ThieryMichel39202cfcaab3
diff --git a/index.html b/index.html
index 0bcc4163..c5141a49 100644
--- a/index.html
+++ b/index.html
@@ -121,5 +121,5 @@
</div>
</div>
</body>
- <script type="module" src="/src/index.tsx"></script>
+ <script type="module" src="/src/script.tsx"></script>
</html>
diff --git a/src/index.tsx b/src/index.tsx
index bbda3918..8da6900d 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -1,18 +1,3 @@
-import React from 'react';
-import { createRoot } from 'react-dom/client';
-import App from './App';
-import reportWebVitals from './reportWebVitals';
+import { CRM } from './root/CRM';
-const container = document.getElementById('root');
-const root = createRoot(container!);
-
-root.render(
- <React.StrictMode>
- <App />
- </React.StrictMode>
-);
-
-// If you want to start measuring performance in your app, pass a function
-// to log results (for example: reportWebVitals(console.log))
-// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
-reportWebVitals();
+export default CRM;
diff --git a/src/script.tsx b/src/script.tsx
new file mode 100644
index 00000000..bbda3918
--- /dev/null
+++ b/src/script.tsx
@@ -0,0 +1,18 @@
+import React from 'react';
+import { createRoot } from 'react-dom/client';
+import App from './App';
+import reportWebVitals from './reportWebVitals';
+
+const container = document.getElementById('root');
+const root = createRoot(container!);
+
+root.render(
+ <React.StrictMode>
+ <App />
+ </React.StrictMode>
+);
+
+// If you want to start measuring performance in your app, pass a function
+// to log results (for example: reportWebVitals(console.log))
+// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
+reportWebVitals();