diff options
| author | Maksymilian Jopek <maks@jopek.eu> | 2021-10-24 18:59:50 +0200 |
|---|---|---|
| committer | Maksymilian Jopek <maks@jopek.eu> | 2021-10-24 18:59:50 +0200 |
| commit | 55d0e202677253ecf893bd52649871f10b52d3de (patch) | |
| tree | 23fc8b3b06bef4ff7503c100edcea2ed01a298d5 /src/index.ts | |
| parent | 94ca5987544009f2da17fe27abc6c9de380d34fd (diff) | |
| download | isiqandisi-55d0e202677253ecf893bd52649871f10b52d3de.tar.gz isiqandisi-55d0e202677253ecf893bd52649871f10b52d3de.tar.zst isiqandisi-55d0e202677253ecf893bd52649871f10b52d3de.zip | |
Almost dragging and WYSiWYG start
Diffstat (limited to 'src/index.ts')
| -rw-r--r-- | src/index.ts | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/index.ts b/src/index.ts index 00391b5..79d5386 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,2 +1,12 @@ -import "@/styles/index.css"; +import "Styles/index.css"; +async function goToMain() { + const i = document.getElementsByTagName("input")[0] + const res = await (await fetch("http://localhost:8000/getFridge.php?name=" + i.value)).text() + sessionStorage.fridge = res; + location.href = "/main.html" +} +declare global { + interface Window { goToMain: () => void; } +} +window.goToMain = goToMain |
