diff options
| author | Melonai <einebeere@gmail.com> | 2021-01-20 23:18:09 +0100 |
|---|---|---|
| committer | Melonai <einebeere@gmail.com> | 2021-01-20 23:18:09 +0100 |
| commit | 826c7c47785ee01d2b9267919132ada696425344 (patch) | |
| tree | 901cc90be9a953a6c3f968b6c1abe33cc13774b4 /client/src/App.js | |
| parent | 2953dec527cedaabaa5f0eb48637c5ddd4a4103b (diff) | |
| download | shorest-826c7c47785ee01d2b9267919132ada696425344.tar.zst shorest-826c7c47785ee01d2b9267919132ada696425344.zip | |
Remade the client in SvelteKit
Diffstat (limited to 'client/src/App.js')
| -rw-r--r-- | client/src/App.js | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/client/src/App.js b/client/src/App.js deleted file mode 100644 index 135a037..0000000 --- a/client/src/App.js +++ /dev/null @@ -1,25 +0,0 @@ -import React, {useState} from 'react'; -import './App.css'; -import Title from './Components/Title'; -import Form from './Components/Form'; -import ResponseContainer from './Components/ResponseContainer'; -import shortid from 'shortid'; - -function App() { - const [requests, setRequests] = useState([]); - - const addRequest = (newRequest) => { - const newRequests = [{url: newRequest, key: shortid.generate()}, ...requests]; - setRequests(newRequests.slice(0, 2)); - } - - return ( - <div> - <Title/> - <Form addRequest={addRequest}/> - <ResponseContainer requests={requests}/> - </div> - ); -} - -export default App; |
