Skip to content

The local provider does not perform font metric optimization #171

Closed

Description

@dungsil

I'm not sure if this is intended, but it appears that the fonts available through the Local provider are not being optimised.

In the screenshot, Inter from google is displayed as ‘Fallback font: Inter’, but Pretendard from local is not.

image

Activity

  1. added a commit that references this issue on Jun 4, 2024
  2. dungsil commented on Jun 4, 2024

    @dungsil
    Author
  3. dosubot commented on Jun 4, 2024

    @dosubot

    Hello, @dungsil! I'm here to assist you with any bugs, questions, or becoming a contributor. Let's tackle this together! 🤖

    The local provider does not perform font metric optimization because the current implementation does not support reading font metrics. This is indicated by a TODO comment in the code:

    // TODO: support reading font metrics

    This means that while the local provider can register and resolve font files, it does not have the capability to optimize font metrics, which is why local fonts like Pretendard are not optimized. In contrast, fonts from Google, like Inter, are likely optimized because the Google provider includes font metric optimization [1][2].

    To continue talking to Dosu, mention @dosu.

  4. asonnleitner commented on Mar 13, 2025

    @asonnleitner

    Any ETA?

  5. added theissue type on May 7, 2025
  6. this-gavagai commented on Jul 7, 2025

    @this-gavagai

    In the meantime, is it recommended to use @nuxtjs/fontaine in addition to this module?

  7. simonhrogers commented on Apr 3, 2026

    @simonhrogers

    @danielroe really enjoyed your video on this module. I’m very keen to see if the fallbacks will slip past the watchful eyes of various designers I work with (they usually express a preference for blocking, if performance can handle it).

    However I work pretty much exclusively with local fonts. From a quick survey of what’s available, the routes available to me right now for Nuxt 4 are:

    1. test an install of just the fontaine package, not @nuxt/fontaine as this hasn’t been updated since Nuxt 3.
    2. manually implement a fallback myself, calculating the values by eye.
  8. NicolaSpadari commented on Jul 22, 2026

    @NicolaSpadari

    Any updates? Local font optimisation though fontaine is very needed for custom design systems.
    Currently working with custom fonts in nuxtui, which lack optimisation ootb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions