retejs / rete

JavaScript framework for visual programming
https://retejs.org
MIT License
10.17k stars 653 forks source link

Uncaught ReferenceError: regeneratorRuntime is not defined #391

Closed yspreen closed 4 years ago

yspreen commented 4 years ago

I know this error was addressed before, but I encountered it because of a completely different reason, and it took me a few hours to figure out why this happened specifically.

If you don't call

editor.on("event", async () => { … });

with at least one valid event, the exception is thrown:

rete.esm.js?f5d5:413 Uncaught ReferenceError: regeneratorRuntime is not defined
    at eval (rete.esm.js?f5d5:413)
    at eval (rete.esm.js?f5d5:437)
    at eval (rete.esm.js?f5d5:477)
    at Module../node_modules/rete/build/rete.esm.js (chunk-vendors.js:13356)
    at __webpack_require__ (app.js:786)
    at fn (app.js:151)
    at eval (cjs.js?!./node_modules/babel-loader/lib/index.js!./node_modules/eslint-loader/index.js?!./src/components/GraphEditor/comp.js?vue&type=script&lang=js&:15)
    at Module../node_modules/cache-loader/dist/cjs.js?!./node_modules/babel-loader/lib/index.js!./node_modules/eslint-loader/index.js?!./src/components/GraphEditor/comp.js?vue&type=script&lang=js& (app.js:923)
    at __webpack_require__ (app.js:786)
    at fn (app.js:151)

Even just having

import Rete from "rete";
export default {};

causes this error.

Ni55aN commented 4 years ago

https://github.com/retejs/rete/issues/247

yspreen commented 4 years ago

I think #247 addresses a different issue, since the event listening isn’t the proposed solution in that issue

Ni55aN commented 4 years ago

This issue isn't related to event listening