From 7bf5ff926af4a0813d62535e0eee6eecdd09a86e Mon Sep 17 00:00:00 2001 From: Seth Trowbridge Date: Mon, 30 Sep 2024 10:41:31 -0400 Subject: [PATCH] separate App --- src/App.tsx | 8 ++++++++ src/main.tsx | 8 +------- 2 files changed, 9 insertions(+), 7 deletions(-) create mode 100644 src/App.tsx diff --git a/src/App.tsx b/src/App.tsx new file mode 100644 index 0000000..31a1d62 --- /dev/null +++ b/src/App.tsx @@ -0,0 +1,8 @@ +import React from 'react' + +export default function App() { + const [count, setCount] = React.useState(0) + return ; +} diff --git a/src/main.tsx b/src/main.tsx index bc11115..1afc83d 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -1,12 +1,6 @@ import React from 'react' import ReactDOM from 'react-dom/client' - -function App() { - const [count, setCount] = React.useState(0) - return ; -} +import App from './App'; const root = document.getElementById('root'); root && ReactDOM.createRoot(root).render(); \ No newline at end of file