flowhub / the-graph

SVG custom elements for FBP graph editing and visualization. Used in noflo/noflo-ui

Home Page:https://flowhub.github.io/the-graph/demo-full.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React16 port

sarat1669 opened this issue · comments

Can we support React16?

The basics work with React16, see this example: #360 (comment)

If you see things that don't work, please post them here as comments!

I would be very happy for a Pull Request that: updates API usage to no longer use deprecated functions, switches to React 16, fixes any critical bugs. Then we could probably switch over right away.

It is unlikely that I will be able to do the port within the next couple of months, unless someone is willing to sponsor such development.

Hi! I'm having problems using the-graph with preact ( https://preactjs.com/ ) which also does not like strings for refs. preact only supports functions as refs. Would the react16 port include functions for refs? I would really like to use the-graph for my current project since it is the best flow based programming graph editor I found during my two days web research. I have some budget for this project so I could sponsor some dev time. Could you please estimate the needed dev time and your hourly rate. If you want we can switch to personal communication for that purpose. My email is: wizards23@gmail.com

@wizard23 I had a quick look at the-graph use of refs. There are not that many, and I think that probably they can all be removed in favor of props/state (or better component composition). Are you aware of other things that cause issues with Preact? Whether it is reasonable to support that in addition to React depends entirely on how much differences there are.

@jonnor

Are you aware of other things that cause issues with Preact?

I'm pretty sure this is the only problem for preact. I've ported some apps tp preact now and this is the only problem that comes up. I can't say for sure though since the ref stuff causes an exception and the rest of the code does not get executed.

@krizka are you aware of other React 16 issues, or do you think we can close this one?

@jonnor I had no problems using the-graph with React 16. But the warnings about static fields on components, which I hope we fixed.

Great, thanks for testing and for the PRs! Closing this issue then.

Right now there is no resources (spare time) to add Preact support on our side. If someone is willing to test and submit a PR with compatibility fixes and these are small, I will consider merging them.