diff options
| author | Adam Soltys <[email protected]> | 2022-07-28 21:22:25 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2022-07-28 21:22:50 -0700 |
| commit | 49e7185efd45add123e0dbfcab077772b5ff22f6 (patch) | |
| tree | b154c499b6c81c3cef0fa42d4c9f44c1f3444034 /src/components | |
| parent | bcb252eb0b52f64449dad295595fdaa5e80cb5dc (diff) | |
| download | coinos-ui-49e7185efd45add123e0dbfcab077772b5ff22f6.tar.gz coinos-ui-49e7185efd45add123e0dbfcab077772b5ff22f6.zip | |
save token in cookie
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/RegisterOrLogin.svelte | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/components/RegisterOrLogin.svelte b/src/components/RegisterOrLogin.svelte index 6cae8b5a..2334741d 100644 --- a/src/components/RegisterOrLogin.svelte +++ b/src/components/RegisterOrLogin.svelte @@ -7,7 +7,7 @@ export let page; - let username, password; + let username = "bob", password = "pw"; let revealPassword = false; @@ -20,6 +20,7 @@ let r = await post(url, { username, password }); if (!r.token) r = await post('/login', { username, password }); $token = r.token; + console.log("new token", r.token) auth(); goto('/receive'); }; @@ -42,6 +43,7 @@ required class="bg-primary p-4 rounded-2xl w-full" bind:value={username} + autofocus /> </div> |
