You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Astro v4.11.5
Node v18.20.3
System Linux (x64)
Package Manager npm
Output static
Adapter none
Integrations none
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
When setting the base url to /base
In dev:
The styles/scripts which are added by astro/vite themselves do not have the base prepended
eg. /@vite/client, all /@fs/*, /node_modules/* etc.
What's the expected result?
All assets should have their urls prepended with base
eg. /base/@vite/client, /base/@fs/*, /base/node_modules/* etc.
In prod the base url works as expected and is prepended to all assets.
This is important in the scenario where astro server is running behind a proxy and we need to forward all assets call to a server.
I didnt find any docs on what urls are used otherwise one hack would be to forward those reqs. but that could break in case we have two astro servers behind a proxy
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
When setting the
base
url to/base
In dev:
The styles/scripts which are added by astro/vite themselves do not have the base prepended
eg.
/@vite/client
, all/@fs/*
,/node_modules/*
etc.What's the expected result?
All assets should have their urls prepended with base
eg.
/base/@vite/client
,/base/@fs/*
,/base/node_modules/*
etc.In a vite react project during dev. when the base is set:
All the scripts/styles injected contain that base path.
Example: https://stackblitz.com/edit/vitejs-vite-nmbndk
In prod the base url works as expected and is prepended to all assets.
This is important in the scenario where astro server is running behind a proxy and we need to forward all assets call to a server.
I didnt find any docs on what urls are used otherwise one hack would be to forward those reqs. but that could break in case we have two astro servers behind a proxy
Link to Minimal Reproducible Example
https://stackblitz.com/edit/withastro-astro-5atatw
Participation
The text was updated successfully, but these errors were encountered: