Created
August 3, 2018 01:31
-
-
Save devmattrick/505618926c84cbedaa821e9a512a0183 to your computer and use it in GitHub Desktop.
Basic node-canvas Typescript Bindings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* These bindings are so you can use node-canvas in your Typescript project without it yelling at you. They will not | |
* provide proper type checking or anything like that. | |
*/ | |
declare module "canvas" { | |
export type Canvas = any; | |
export type Context2d = any; | |
export type CanvasRenderingContext2D = any; | |
export type CanvasGradient = any; | |
export type CanvasPattern = any; | |
export type Image = any; | |
export type ImageData = any; | |
export type PNGStream = any; | |
export type PDFStream = any; | |
export type JPEGStream = any; | |
export type DOMMatrix = any; | |
export type DOMPoint = any; | |
export function registerFont(...args: any[]): any; | |
export function parseFont(...args: any[]): any; | |
export function createCanvas(...args: any[]): any; | |
export function createImageData(...args: any[]): any; | |
export function loadImage(...args: any[]): any; | |
export const backends: any; | |
export const version: any; | |
export const cairoVersion: any; | |
export const jpegVersion: any; | |
export const gifVersion: any; | |
export const freetypeVersion: any; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment