Installation
npm install --save @types/webfontloader
Summary
This package contains type definitions for webfontloader (https://github.com/typekit/webfontloader).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/webfontloader.
export = WebFont;
export as namespace WebFont;
declare namespace WebFont {
export function load(config: WebFont.Config): void;
export interface Config {
classes?: boolean | undefined;
events?: boolean | undefined;
timeout?: number | undefined;
loading?(): void;
active?(): void;
inactive?(): void;
fontloading?(familyName: string, fvd: string): void;
fontactive?(familyName: string, fvd: string): void;
fontinactive?(familyName: string, fvd: string): void;
context?: Window | undefined;
custom?: Custom | undefined;
google?: Google | undefined;
typekit?: Typekit | undefined;
fontdeck?: Fontdeck | undefined;
monotype?: Monotype | undefined;
}
export interface Google {
api?: string | undefined;
families: string[];
text?: string | undefined;
}
export interface Typekit {
id?: string | undefined;
}
export interface Custom {
families?: string[] | undefined;
urls?: string[] | undefined;
testStrings?: { [fontFamily: string]: string } | undefined;
}
export interface Fontdeck {
id?: string | undefined;
}
export interface Monotype {
projectId?: string | undefined;
version?: number | undefined;
loadAllFonts?: boolean | undefined;
}
}
Additional Details
- Last updated: Mon, 20 Nov 2023 23:36:24 GMT
- Dependencies: none
Credits
These definitions were written by SECT.