Skip to content

Commit

Permalink
Merge pull request #80 from edivados/css-asset-href
Browse files Browse the repository at this point in the history
fix: css asset href is relative
  • Loading branch information
nksaraf committed Jan 4, 2024
2 parents 76f575e + 6f695e2 commit 6db755c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/three-trainers-fetch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"vinxi": patch
---

fix: css asset href is relative
2 changes: 1 addition & 1 deletion packages/vinxi/lib/manifest/prod-server-manifest.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function createHtmlTagsForAssets(router, app, assets) {
.map((asset) => ({
tag: "link",
attrs: {
href: joinURL(app.config.server.baseURL ?? "", router.base, asset),
href: joinURL(app.config.server.baseURL ?? "/", router.base, asset),
key: join(app.config.server.baseURL ?? "", router.base, asset),
...(asset.endsWith(".css")
? { rel: "stylesheet", precendence: "high" }
Expand Down

0 comments on commit 6db755c

Please sign in to comment.