Skip to content

Commit

Permalink
Offscreencanvas error fix (#308)
Browse files Browse the repository at this point in the history
* Fixes #305 - offscreencanvas error

* Bump version to pre.2
  • Loading branch information
HarelM authored Sep 4, 2021
1 parent 8216085 commit 086b97f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "maplibre-gl",
"description": "BSD licensed community fork of mapbox-gl, a WebGL interactive maps library",
"version": "2.0.0-pre.1",
"version": "2.0.0-pre.2",
"main": "dist/maplibre-gl.js",
"style": "dist/maplibre-gl.css",
"license": "BSD-3-Clause",
Expand Down
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 086b97f

Please sign in to comment.