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

Updating for compatibility with three@>=0.80.0 #126

Merged
merged 3 commits into from
Dec 4, 2016

Conversation

foorjdev
Copy link
Contributor

This PR moves toward compatibility with react@>=0.80.0, though some issues still remain. The main problem I'm running into is that for some reason prop type validation fails whenever THREE entities are passed as props (e.g. passing a THREE.Vector3 for position). Despite spending a fair amount of time trying to follow the exact sequence of function calls involved in prop validation, I'm still unable to locate the source of the failure.

If I understand correctly, THREE entities are validated by looking at the name of the constructor (for example, if we have var v = new THREE.Vector3(), then v.constructor.name === 'Vector3'). But this appears to be entirely consistent with three@>=0.80.0, leading to very strange validation error messages like Failed prop type: Invalid prop 'position' of type 'Vector3' supplied to 'perspectiveCamera', expected instance of 'Vector3'.

Finally, I've added an implementation of THREE.HemisphereLight, though no tests have been written for it yet.

@toxicFork
Copy link
Collaborator

Awesome, thanks! I will take a look to see how we can resolve the issues you mentioned :)

toxicFork added a commit that referenced this pull request Nov 20, 2016
@toxicFork
Copy link
Collaborator

Woo, solved the issues! Let's see what travis says and we can merge to master :D

Also will need to update the examples... Doing that now :)

Thanks for the help @foorjdev !!! ❤️

@toxicFork toxicFork added this to the 3.0.0 milestone Nov 20, 2016
toxicFork added a commit that referenced this pull request Nov 20, 2016
@toxicFork toxicFork merged commit c82ec25 into firtoz:master Dec 4, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants