reaviz / reaflow

🎯 React library for building workflow editors, flow charts and diagrams. Maintained by @goodcodeus.

Home Page:https://reaflow.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Canvas not rendering due a webpack error

carlescamig opened this issue · comments

I'm using umi.js as my framework. Since reafow v5.2 I'm getting the following console error:

Layout Error: TypeError: calculate_size__WEBPACK_IMPORTED_MODULE_5__ is not a function

I also tried with a umi fresh install without dependencias and I get the same error. Here's a screenshot

The implementation code is the following:

import { Canvas } from 'reaflow';

export default function HomePage() {
  return <>
  <Canvas
    maxWidth={800}
    maxHeight={600}
    nodes={[
      {
        id: '1',
        text: '1'
      },
      {
        id: '2',
        text: '2'
      }
    ]}
    edges={[
      {
        id: '1-2',
        from: '1',
        to: '2'
      }
    ]}
  />;
  </>
}

Browser:

  • Chrome (desktop) Versión 115.0.5790.170 (Build oficial) (x86_64)
    For Tooling issues:
  • Node version: 16.18
  • UmiJS version: 4.0.76
  • Platform: Mac