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
I am willing to submit a pull request for this issue.
The text was updated successfully, but these errors were encountered:
Tanguy-Magnaudet
changed the title
Prefect integration doesn't prepend the src path with the config.base
Prefetch integration doesn't prepend the src path with the config.base
Dec 9, 2022
I don't really know how astro works behind the scene but I only face the problem with that script tag with the page.5a6f3db5.js
Inside that file I found some error messages related to the Prefetch integration so I assumed it was related.
The base is correctly applied with every other files in the client folder generated by the build.
@matthewp if this helps, I reproduced the issue and the funny thing is that the page.xxx.js was served on both base and non base when running node in standalone, but the script tag is lacking the base which make it not work when you need to deploy the script only on base and not on root.
What version of
astro
are you using?1.6.14 // prefect is 0.1.1
Are you using an SSR adapter? If so, which one?
Node
What package manager are you using?
pnpm
What operating system are you using?
linux
Describe the Bug
When you add a base in the astro.config.mjs, it is not used by the prefetch integration in SSR mode.
Here is a discord support ticket with more details : How can I prefix assets href in SSR ?
This is what I get with the base configured as 'dist/views' :
And this is what I expect :
Link to Minimal Reproducible Example
https://codesandbox.io/p/sandbox/frosty-glitter-we1x6f?file=%2Fastro.config.mjs&selection=%5B%7B%22endColumn%22%3A41%2C%22endLineNumber%22%3A11%2C%22startColumn%22%3A41%2C%22startLineNumber%22%3A11%7D%5D&workspace=%257B%2522activeFileId%2522%253A%2522cl8vqm78z0002lthi55o15wef%2522%252C%2522openFiles%2522%253A%255B%2522%252Fpackage.json%2522%252C%2522%252Fastro.config.mjs%2522%255D%252C%2522sidebarPanel%2522%253A%2522EXPLORER%2522%252C%2522gitSidebarPanel%2522%253A%2522COMMIT%2522%252C%2522spaces%2522%253A%257B%2522clbg8tv41000u3b6ggw4fddcz%2522%253A%257B%2522key%2522%253A%2522clbg8tv41000u3b6ggw4fddcz%2522%252C%2522name%2522%253A%2522Default%2522%252C%2522devtools%2522%253A%255B%257B%2522type%2522%253A%2522UNASSIGNED_PORT%2522%252C%2522port%2522%253A3000%252C%2522url%2522%253A%2522we1x6f-3000.preview.csb.app%2522%252C%2522key%2522%253A%2522clbg95eex029z3b6g8lfor6v7%2522%252C%2522isMinimized%2522%253Afalse%257D%252C%257B%2522type%2522%253A%2522TERMINAL%2522%252C%2522shellId%2522%253A%2522clbg8zzwd00427qhifn67898s%2522%252C%2522key%2522%253A%2522clbg8zzrv00vo3b6gc9ffqhq0%2522%252C%2522isMinimized%2522%253Afalse%257D%255D%257D%257D%252C%2522currentSpace%2522%253A%2522clbg8tv41000u3b6ggw4fddcz%2522%252C%2522spacesOrder%2522%253A%255B%2522clbg8tv41000u3b6ggw4fddcz%2522%255D%257D
Participation
The text was updated successfully, but these errors were encountered: