Skip to content

fix: serve static files from pwa if not found in api#2710

Open
ibousfiha wants to merge 2 commits intoapi-platform:mainfrom
ibousfiha:main
Open

fix: serve static files from pwa if not found in api#2710
ibousfiha wants to merge 2 commits intoapi-platform:mainfrom
ibousfiha:main

Conversation

@ibousfiha
Copy link

Hi, this PR is to serve static files like svgs from pwa if not found in api.
Please let me know if it fits or updates are required.

Q A
Branch? main
Tickets Closes #..., closes #...
License MIT
Doc PR api-platform/docs#...

@soyuka soyuka requested a review from dunglas November 6, 2024 21:50
@dunglas
Copy link
Member

dunglas commented Nov 25, 2024

Good idea, but this will prevent the API from serving files with this extension if any.

We should use try_files to first check if the file exists API-side, and redirect to the PWA if it's not the case. This will have the added benefit of working with any file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants