Skip to content

Fonts for nested routes are not loaded properly #32

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
taranek opened this issue Oct 17, 2022 · 2 comments
Closed

Fonts for nested routes are not loaded properly #32

taranek opened this issue Oct 17, 2022 · 2 comments

Comments

@taranek
Copy link

taranek commented Oct 17, 2022

Hey, thank you for a great plugin!
I'm having an issue when loading fonts from a nested route. Here's an example where you can reproduce the issue:
https://stackblitz.com/edit/vitejs-vite-font-plugin-bug?file=src%2FApp.tsx

Steps to reproduce:

  1. Go to /a/b/c route in the sandbox and refresh a page, check the network tab to see 404 error.

I think the issue is caused by injecting a relative path instead of an absolute one as a href attribute in the link tag. I'll post a PR that fixes the issue soon.

@stafyniaksacha
Copy link
Member

This will be fixed with #39

@stafyniaksacha
Copy link
Member

Hi @taranek!

This has been fixed in the v1.0.0

Feel free to reopen the issue if it persists!

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

No branches or pull requests

2 participants