Skip to content

Fonts aren't loading in web #104

Description

@sscssc11

I'm using two fonts, inter and oswald. Everything works fine on native ios and android, but on web the fonts do not load. I don't know what the root cause is, but console logging the font says

Screenshot 2023-10-17 at 11 59 42 AM

But if I look in the file structure I don't see a media folder under static. Only "js", which has "bundle.js":

Screenshot 2023-10-17 at 12 01 18 PM

There is no error anywhere, and the font family is reference as such:

Screenshot 2023-10-17 at 12 29 58 PM

but it just loads some default serif font.

Is there something related to webpack that I don't know about? Running "expo export:web" does create a "static/media" folder with the correct files.

Expo: 49.0.10
@expo-google-fonts/inter: ^0.2.3
@expo-google-fonts/oswald: "^0.2.3
@expo/webpack-config: ^19.0.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions