Skip to content
This repository was archived by the owner on Sep 3, 2020. It is now read-only.
This repository was archived by the owner on Sep 3, 2020. It is now read-only.

Issues with loading assets in webpack #15

@tonybennett

Description

@tonybennett

Unable to load fonts with the current loader config and not sure what the issue is so I'm opening a ticket.

  1. Raising limit to ensure base64 encoded file works fine, so it has something to do with URL loading

{ test: /\.(gif|svg|jpg|jpeg|png|woff|woff2|ttf|eot)$/, loader: 'url-loader?limit=8192', include: constants.SRC_DIR }

  1. Prefixing the asset url with ~!url! also works.

example: prefixing ../../assets/fonts/fontname.woff2 as ~!url!../../assets/fonts/fontname.woff2 works fine

  1. Also thinking that maybe we should always be using url loading rather than base64 encoding web fonts, since there's generally multiple formats, there's not much sense in encoding them all to include in the css.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions