8 lines
233 B
JavaScript
8 lines
233 B
JavaScript
export function createCanvas() {
|
|
if (typeof document !== 'undefined') {
|
|
return document.createElement('canvas');
|
|
} else {
|
|
throw new Error('Cannot create a canvas in this context');
|
|
}
|
|
}
|
|
//# sourceMappingURL=canvas.js.map
|