From 326f346936e79e5da8a36fdb3a47e11aaff15a35 Mon Sep 17 00:00:00 2001 From: Dominik Schmidt Date: Tue, 14 Jun 2022 22:54:00 +0200 Subject: [PATCH] Import default export if node is a transpiled es module --- packages/node_modules/@node-red/registry/lib/loader.js | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/node_modules/@node-red/registry/lib/loader.js b/packages/node_modules/@node-red/registry/lib/loader.js index fc508aa57..61f28ab86 100644 --- a/packages/node_modules/@node-red/registry/lib/loader.js +++ b/packages/node_modules/@node-red/registry/lib/loader.js @@ -359,6 +359,7 @@ function loadNodeSet(node) { try { var loadPromise = null; var r = require(node.file); + r = r.__esModule ? r.default : r if (typeof r === "function") { var red = registryUtil.createNodeApi(node);