projectstorm / react-diagrams

a super simple, no-nonsense diagramming library written in react that just works
https://projectstorm.cloud/react-diagrams
MIT License
8.45k stars 1.16k forks source link

PortWidget cannot be used as a JSX component #969

Open loziobrus opened 1 year ago

loziobrus commented 1 year ago

After updating to React 18 and to v6.7.4 every PortWidget and LinkWidget are failing to render and throw following ts error:

JSX element class does not support attributes because it does not have a 'props' property.ts(2607) 'PortWidget' cannot be used as a JSX component. Its instance type 'PortWidget' is not a valid JSX element. Type 'PortWidget' is missing the following properties from type 'ElementClass': context, setState, forceUpdate, props, and 2 more.ts(2786).

Usage is as simple as that:

...
electronicalias commented 7 months ago

I'm getting this also.