Skip to content
This repository has been archived by the owner on Jul 20, 2020. It is now read-only.

React v 16.0.0 support #197

Open
nehvaleem opened this issue Sep 29, 2017 · 32 comments
Open

React v 16.0.0 support #197

nehvaleem opened this issue Sep 29, 2017 · 32 comments

Comments

@nehvaleem
Copy link

Hi,
are there any plans to support React 16.0.0? After updating I've got an error:

Module not found: Can't resolve 'react/lib/ReactComponentWithPureRenderMixin' in '/home/project/frontend/node_modules/react-three-renderer/lib'

If so - are there any ETA?

@toxicFork
Copy link
Collaborator

toxicFork commented Sep 29, 2017 via email

@toxicFork
Copy link
Collaborator

Todo: add big red warning to readme

@jugglingcats
Copy link

jugglingcats commented Sep 29, 2017

Hi, be interesting to know if using fibre and your react-three-renderer-fiber might help with #127 and how else it might fundamentally affect R3R usability / extensibility? Would it be backwards compatible (if it's not there may be opportunities to make it more Typescript friendly!).

@toxicFork
Copy link
Collaborator

some specific research will still need to be done e.g. To have typescript compatibility with custom renderers. I'm guessing some sort of tool to take component types, attribute types to generate tsd output for "new natives"?

@jugglingcats
Copy link

Hi, for better Typescript support there are a couple of things needed:

  • TSD file needs to be created. This can be hand-crafted, generated from jsdoc, or you can code in Typescript from the outset and the compiler will generate the tsd file for you (tsc -d)
  • The problem with lowercased intrinsic elements needs to be solved. I don't know if there is a solution actually, so I wonder if using initial caps for R3R elements is a possibility. Obviously this would be a breaking change so can understand it might not fly!

Thanks

@toxicFork
Copy link
Collaborator

toxicFork commented Sep 30, 2017 via email

@jugglingcats
Copy link

Exciting!

@jardakotesovec
Copy link
Contributor

@toxicFork Good news on fiber implementation, but may I ask, whats the motivation for using typescript for new implementation? I suspect that code base ends up less approachable for contributors as majority devs deal just with javascript.

@toxicFork
Copy link
Collaborator

Once I added the type checking it makes it so much faster and easier to make something that works!

Especially when dealing with such uncharted territory (at least for myself), having the type hints is a really good support.

Yes, unfortunately it will mean making it harder for contributors... that's indeed a problem. I'm hoping it won't be "too hardcore typescript" at least :)

@jardakotesovec
Copy link
Contributor

@toxicFork On different note. Do you think that it would be feasible to make new implementation somewhat modular, similarly as current Three.js? It would be awesome if would be possible to avoid bundling complete Three.js and r3r when using only few elements.

@toxicFork
Copy link
Collaborator

🤔...
🤔...
Maybe...

@jardakotesovec
Copy link
Contributor

@toxicFork And is not flow more suitable since react use that? There is discussion about exposing react reconciler and there is definitely intention to include flow types for that api.

Disclaimer: I don't have personal experience with neither flow or typescript.

@toxicFork
Copy link
Collaborator

I considered flow and sided with TypeScript, as it has more benefits. If something works with flow it should also work with TS anyway, and also thank you for linking to that discussion, I had to link to my own build of the fiber reconciler to do some testing :D

@toxicFork
Copy link
Collaborator

facebook/react#10758 just landed! I'm going to give it a try and feed information back to fb to help resolve potential problems, meanwhile I'm also redesigning parts of the core to make more sense... Exciting times.

@toxicFork
Copy link
Collaborator

https://www.npmjs.com/package/react-reconciler still at v0 (i.e. not published) but once it's out I'll post an update here :)

I have subscribed to facebook/react#9103 so I'm guessing that one will be closed once the publishing happens.

@pasih
Copy link

pasih commented Nov 7, 2017

react-reconciler 0.2.0 is available (together with React 16.1 beta) (react-konva is already using it and it looks like its working alright).

@johnrees
Copy link
Contributor

johnrees commented Nov 7, 2017

Related: firtoz/react-three-renderer-fiber#24

@toxicFork
Copy link
Collaborator

@pasih nice :D

@jardakotesovec
Copy link
Contributor

@toxicFork Hey, just wondering, do you have any update on react-three-rendered-fiber progress? The repo seems quiet lately :-).

@toxicFork
Copy link
Collaborator

Hi, apologies on the quietness, having another chaotic period. I'm not sure when things will cool down, I'm hoping for sometime in January.

@sompylasar
Copy link

sompylasar commented Dec 12, 2017

@toxicFork Have you pushed all the code you have locally? It'd be fun to experiment with.

@toxicFork
Copy link
Collaborator

toxicFork commented Dec 12, 2017

Just checked my repos and it is up to date for react-three-renderer,

https://github.com/toxicFork/react-three-renderer-fiber

It looks like I had branched off to "create-react-renderer" to allow making "any kind of custom react renderer" with a similar file structure, but that's a distraction I should have prevented. Depends on what the end goal is.

That distraction is in https://github.com/toxicFork/react-three-renderer-fiber/commits/create-react-renderer .

And the diff in https://github.com/toxicFork/react-three-renderer-fiber/compare/create-react-renderer?expand=1

@sompylasar
Copy link

@toxicFork Which branch is better to play with, continue development on: master or the "distraction" branch, create-react-renderer? Do you plan to abandon the "distraction"?

@toxicFork
Copy link
Collaborator

toxicFork commented Dec 12, 2017 via email

@PolGuixe
Copy link

PolGuixe commented Jun 1, 2018

@toxicFork what the current plan for this repo?

Is R3R no usable at all with React 16?

@nickpolet
Copy link

I'm looking for react 16 comparability as well. Really frustrated to not have it with this library. I understand that it's a fairly large overhaul to get it working well with fibers.

@toxicFork Do you have any updates on react-three-renderer-fiber? Would be good to know if that has stalled or not.

@toxicFork
Copy link
Collaborator

toxicFork commented Jun 9, 2018 via email

@Aarbel
Copy link

Aarbel commented Aug 2, 2018

HI, when react-three will be compatible with React 16 ?

@toxicFork
Copy link
Collaborator

Hey @Aarbel, thank you for your interest in the project. I'm hoping for some time this year, but the development is very on and off at this point so it's quite hard to make estimates unfortunately.

@ekatzenstein
Copy link

@toxicFork I'm unfortunately going to have to stop using this library if a React 16 update doesn't happen soon. There are other libraries (like material-ui) that now only work with React 16 and it's difficult to balance with legacy React.

@toxicFork
Copy link
Collaborator

toxicFork commented Oct 21, 2018

Hi @ekatzenstein I'm sorry to hear that. The current status of the sister "more react 16 compatible" repository https://github.com/toxicFork/react-three-renderer-fiber is that it's "mostly functional".

The plan is to convert all examples from https://github.com/toxicFork/react-three-renderer-example repository to be able to use https://github.com/toxicFork/react-three-renderer-fiber, then I'll push a new commit into this repo ( https://github.com/toxicFork/react-three-renderer ) with the contents of the other one and there will be a npm publish of a new version of react-three-renderer.

There will be some work necessary for upgrades and to resolve breaking changes but as the tutorials are converted I'm hoping to find out the main troublemakers and hopefully eliminate them.

The ETA is still very much up in the air, I'm guessing I may regret saying "sometime this year".

@ekatzenstein
Copy link

ekatzenstein commented Oct 21, 2018 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests