what do you think is the best way to protect uploaded files in a single page application?
Fore example lets say there is the frontend www.myapp.tld and the backend api.myapp.tld.
Frontend and Backend are fully separated and the frontend is running on vue-cli.
If a user uploads a PDF file it will be stored on api.myapp.tld and returns the URL of the file: api.myapp.tld/files/my-file.pdf
Now everyone could access to the file but only the logged in user should be able to access it.
Whats the best way to protect uploaded files for each user?