【问题标题】:Rete Library giving error with React JS : ReferenceError: regeneratorRuntime is not definedRete 库在 React JS 中出现错误:ReferenceError: regeneratorRuntime is not defined
【发布时间】:2020-08-19 08:30:44
【问题描述】:

Rete 库在安装时出现以下错误。以下是我遇到的错误。

(anonymous function)
node_modules/rete/build/rete.esm.js:413
  410 | value: function () {
  411 |   var _build = _asyncToGenerator(
  412 |   /*#__PURE__*/
> 413 |   regeneratorRuntime.mark(function _callee(node) {
  414 |     return regeneratorRuntime.wrap(function _callee$(_context) {
  415 |       while (1) {
  416 |         switch (_context.prev = _context.next) {

【问题讨论】:

    标签: reactjs rete


    【解决方案1】:

    我找到了解决方案。这里我已经安装了 rete 以及其他一些 rete 插件,如下所示。

    npm i --save rete rete-react-render-plugin rete-connection-plugin rete-area-plugin 
    

    Rete 库有一些依赖关系,可以通过在你的 react js 项目的 index.html 文件中粘贴以下行来解决。

    <script src="https://cdn.jsdelivr.net/npm/rete@1.0.0-alpha.9/build/rete.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/rete-vue-render-plugin@0.2.0/build/vue-render-plugin.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/rete-connection-plugin@0.1.2/build/connection-plugin.min.js"></script>
    

    【讨论】:

      猜你喜欢
      • 2020-12-03
      • 2021-01-16
      • 1970-01-01
      • 1970-01-01
      • 2021-07-12
      • 2021-10-18
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多