swagger-editor
swagger-editor copied to clipboard
LocalStorage persistence does not work with Docker deployment
Q&A
- OS: Windows 11
- Browser: Firefox, Thorium (chromium fork)
- Version: FF: 131.0.3, Thorium: 126.0.6478.231
- Method of installation: Docker
- Swagger-Editor version: v5 latest
- Swagger/OpenAPI version: OpenAPI 3.1
Content & configuration
Example Swagger/OpenAPI definition: Petstore example, or anything else, does not matter to the subject of this issue.
Swagger-Editor configuration options: No editor configuration possible through Docker deployment.
Docker command:
sudo docker run --rm -p 8080:8080 swaggerapi/swagger-editor:next-v5-unprivileged
Describe the bug you're encountering
As said in the title, the local storage does not store the editor content, gets overwritten with {} on every load.
To reproduce...
Steps to reproduce the behavior:
- Start an editor instance with Docker
- Open the editor
- Edit anything, or load an example
- Close the tab
- Open the editor
- The editor content is erased.
Expected behavior
Editor content is persisted with local storage.
Screenshots
The video is recorded on an instance hosted behind a reverse proxy, however this does not effects the issue, as the behavior remains the same with a locally ran instance started by docker run.