Web client built with SvelteKit, which relies on Svelte and Vite.
- Backend infrastructure is created and you have the invoke URLs in hand.
- Create a
.envfile from the.env.examplefile - Add the env vars
npm installto install dependencies
npm run devto run in development mode with hot module replacementnpm run buildto build production sitenpm run previewto view production site
I use Firebase Hosting, but you can host wherever you want.
To use Firebase Hosting:
- Install the Firebase CLI
- Deploy with
npm run deploy
An access token with a 1 month expiry is stored in IndexedDB. Reasons:
- Data stored for this app is not particularly sensitive
- Straightforward to revoke access tokens by changing the password
- HTTP-only cookies are not convenient for localhost development
- Web workers have access to IndexedDB
Of course, make your own judgement based on your own requirements. This is acceptable for me for this use case.