ExportedFont
type ExportedFont = {
font: SubsettedFont;
familyInfo: { differingAxes: Set<string>; overrideName: string | null };
cssName: string;
filename: string;
data: {
opentype: Uint8Array<ArrayBuffer> | null;
woff: Uint8Array<ArrayBuffer> | null;
woff2: Uint8Array<ArrayBuffer> | null;
};
charsetNameOrIndex: string
| number
| null;
extension(format: "opentype" | "woff" | "woff2"): string;
}
Index
Properties
Methods
Properties
font
The subsetted font.
familyInfo 
Info shared among all exported fonts within a family.
Type Declaration
differingAxes: Set<string>Axes that differ among font faces within this family (for example, axes that were instanced into multiple fonts, or where there were multiple static input fonts to begin with). This includes "wght", "wdth", "ital", and "slnt" axes.
overrideName: string | nullIf set, ignore
font.familyNameand treat this as the family name instead. This does not include any disambiguations provided in the ExportedFont#cssName property.
cssName 
The font's family name, as it should be used in CSS.
While the CSS @font-face declaration allows fonts to specify their location in a design space along the weight,
width, and slope axes, it does not allow this for arbitrary axes. So, if an input font is instanced along one
of those axes, each instance will be given a unique CSS name.
Because of this, different fonts in the same source family can end up with different CSS family names.
filename
The font's filename, sans extension.
data
opentype: Uint8Array<ArrayBuffer> | null;
woff: Uint8Array<ArrayBuffer> | null;
woff2: Uint8Array<ArrayBuffer> | null;
}
The font file data, in all the formats requested to export to.
Type Declaration
opentype: Uint8Array<ArrayBuffer> | nullThis aliases to
font.data, but is only present if the'ttf'format was enabled during export.woff: Uint8Array<ArrayBuffer> | nullwoff2: Uint8Array<ArrayBuffer> | null
charsetNameOrIndex   
If this font's source file was instanced into multiple character sets, this tells you which one this exported font is. Used for disambiguating filenames.
Methods
extension
extension(format: "opentype" | "woff" | "woff2"): string
Return this font's filename's extension for a given format, without a leading dot. For woff and woff2, this is simple, but for the uncompressed
'opentype'format, it can be either'ttf'or'otf'.Parameters
format: "opentype" | "woff" | "woff2"
The format to get the extension for.
Returns
string
An exported font, in all its formats.