Skip to content
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

Fonts sometimes don't load correctly #68

Open
h16nning opened this issue Feb 22, 2024 · 8 comments
Open

Fonts sometimes don't load correctly #68

h16nning opened this issue Feb 22, 2024 · 8 comments
Labels
bug Something isn't working

Comments

@h16nning
Copy link
Owner

@merzh

After #67 local fonts aren't always loaded correctly and will resort to system default sans-serif / serif.

This doesn't always happen, actually quite inconsistently, usually after multiple page reloads after each other.

Reproced it in chromium-based, webkit-based and firefox browsers.

Console logs

chromium:
Bildschirmfoto 2024-02-22 um 21 05 13

firefox:
Bildschirmfoto 2024-02-22 um 21 11 04

I haven't figured out yet why it occurs. I suppose something with vites static imports?

@h16nning h16nning reopened this Feb 23, 2024
@h16nning
Copy link
Owner Author

Still occurs sometimes

@h16nning h16nning added the bug Something isn't working label Feb 23, 2024
@h16nning
Copy link
Owner Author

might actually be fixed... hard to reproduce. I think the caching caused some issues too. But I removed that for now

@eMerzh
Copy link
Collaborator

eMerzh commented Feb 25, 2024

arg didn't saw the issue ... hum i'll check that 🤔 not sure why .. i haven't see any issue here

@eMerzh
Copy link
Collaborator

eMerzh commented Feb 25, 2024

mmh yeah, tried multiple refresh in firefox as well as chrome & pwa on chrome... no luck reproducing this 🤔

maybe we can close unless we can reproduce

@h16nning
Copy link
Owner Author

definitely still happens to me (just now) 😅, but mostly when other errors occur so maybe that stops it from loading the fonts

@eMerzh
Copy link
Collaborator

eMerzh commented Feb 25, 2024

hum ok, in local (if i see the pic correctly) ? I saw some ref to low mem issues... 🤔

mmh I'll look at it

@eMerzh
Copy link
Collaborator

eMerzh commented Feb 25, 2024

seeing from you sshot that the url of the font is wrong 🤔 but i see you changed it to '../' ... maybe setting them as absolute? url(/fonts/... ?

@h16nning
Copy link
Owner Author

screenshot was taken before I changed it to ../. with absolute file paths it was happening more consistently.

If I understood the vite docs correctly, relative is the correct way(?)

But this only happens while hot reloading with other errors occurring for me (sometimes) and not at all in the development build as far as I can tell, so it doesn't matter really...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants