Skip to content

Commit

Permalink
Fixes #305 - offscreencanvas error
Browse files Browse the repository at this point in the history
  • Loading branch information
HarelM committed Sep 4, 2021
1 parent 8216085 commit f13f67f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util/offscreen_canvas_supported.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ let supportsOffscreenCanvas: boolean | undefined | null;

export default function offscreenCanvasSupported(): boolean {
if (supportsOffscreenCanvas == null) {
supportsOffscreenCanvas = OffscreenCanvas &&
supportsOffscreenCanvas = typeof OffscreenCanvas !== 'undefined' &&
new OffscreenCanvas(1, 1).getContext('2d') &&
typeof createImageBitmap === 'function';
}
Expand Down

0 comments on commit f13f67f

Please sign in to comment.