Installation
npm install --save @types/string-pixel-width
Summary
This package contains type definitions for string-pixel-width (https://github.com/adambisek/string-pixel-width#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/string-pixel-width.
index.d.ts
export = getWidth;
declare function getWidth(string: string, settings?: Settings): number;
interface Settings {
bold?: boolean | undefined;
font?:
| "andale mono"
| "arial"
| "avenir"
| "avenir next"
| "comic sans ms"
| "courier new"
| "georgia"
| "helvetica"
| "impact"
| "open sans"
| "quantify"
| "tahoma"
| "times new roman"
| "trebuchet ms"
| "verdana"
| "webdings"
| undefined;
italic?: boolean | undefined;
size?: number | undefined;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 15:11:36 GMT
- Dependencies: none
Credits
These definitions were written by Graham Dyson.