Send the play queue ID to the server
Build and Release / build (push) Successful in 33s
Build and Release / release (push) Successful in 9s

The server keeps a play queue per client, identified by the X-Queue-Id
header. Send the stored ID with every request and save the ID from every
response, so the client switches to the new queue after a reset or a sync.
The ID is kept in localStorage so a page reload keeps the same queue.

Also send Cache-Control: no-cache, so browsers that cached a random song
before the server sent no-store fetch a new one.
This commit is contained in:
Sansan committed 2026-10-07 20:09:31 +02:00
1 parent b3ffef9fd9
commit f26438abe0
2 files changed
+47 -1

No files matched your search

+1 -1
View File
@@ -25,7 +25,7 @@ The Docker image writes `config.js` from `public/config.template.js` when the co
| Variable | Description |
|---|---|
| `API_HOSTNAME` | URL of the MusicServer, for example `https://music.example.com`. Empty to use the same host as the frontend. |
| `API_HOSTNAME` | URL of the MusicServer, for example `https://music.example.com`. Empty to use the same host as the frontend. On another host, add the frontend's origin to the server's `CORS_ALLOWED_ORIGINS`. |
| `API_PASSWORD` | The MusicServer's `API_PASSWORD`, used to get an API token. Empty if the server has no password. Anyone who can open the frontend can read it. |
For `npm run serve`, create `public/config.js` (ignored by git):