mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Import default export if node is a transpiled es module
This commit is contained in:
parent
8762d0e164
commit
326f346936
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user