airsonic-ui
airsonic-ui copied to clipboard
Login form is briefly flashing
To reproduce:
- Login
- Open some link in the app, for example an album
- Copy the url
- Paste it into a new tab
Behavior:
Before being redirected you can briefly see the login form after the loading spinner.
Expected behavior:
The loading spinner should be the only thing we see.
This is because the app finishes the boot process after we have verified our credentials (or made sure there aren't any. The relevant code is here: https://github.com/heyarne/airsonic-ui/blob/727d4548718a96867d5eb9ecc9daff752518b6c4/src/cljs/airsonic_ui/subs.cljs#L5-L12
As soon as we have credentials, :events/logged-in is fired, which only then redirects, thus causing the flashing.