1.1.0 • Published 6 years ago

webfont-loader v1.1.0

Weekly downloads
96
License
MIT
Repository
github
Last release
6 years ago

webfont-loader npm version

Load webfont using native FontFace with fall back to font-face-observer (see web font loading detection, without timers for details on how the fallback works).

Assumptions:

  • have font in WOFF format
  • font src is a HTTP or HTTPS URL

Example

var webFontLoader = require('webfont-loader');

webFontLoader('My Font Family', {src: ['http://some.cdn.example.com/my_font.woff']}).then(
  function fontLoaded() {
    // ...
  },
  function fontFailedToLoad() {
    // ...
  }
);
1.1.0

6 years ago

1.0.0

8 years ago

0.1.0

9 years ago

0.0.11

9 years ago

0.0.10

9 years ago

0.0.8

9 years ago

0.0.7

9 years ago

0.0.6

9 years ago

0.0.5

9 years ago

0.0.4

9 years ago

0.0.3

9 years ago

0.0.2

9 years ago

0.0.1

9 years ago