From 0be8e779bcf863acaa6743870f945d5a3fc1171f Mon Sep 17 00:00:00 2001 From: VladimirTechMan Date: Sun, 20 Jan 2019 12:12:12 +0300 Subject: [PATCH] Fix the calls to getGlobalKonva() inside the current code base Following the recent migration to TypeScript, getGlobalKonva() returns undefined (as glob.Konva was not set) when using konva.js or konva.min.js inside a web application running in a browser. This change works around the situation by explicitly setting the Konva property on the glob object. --- src/index.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/index.ts b/src/index.ts index aeb7e1cf..b87f6ddc 100644 --- a/src/index.ts +++ b/src/index.ts @@ -50,4 +50,6 @@ Konva.angleDeg = true; */ Konva.showWarnings = true; +Konva.glob.Konva = Konva; + export default KonvaInternals;