-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Supported React's new Context Api #160
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gets the build working
It worked!!
There was odd state/props combo for name/initial name. React 16.3 doesn't like willReceiveProps anyway. So went with navigating on change instead
There's a React bug with the check - click Name sorter twice and it gets stuck - React fibre's in some infinite loop. Think it worked before 16.3 but the check isn't doing anything because it checks all props so ok to remove
Changed context tests so that context passed down to children. Didn't matter before because Link was the top level before - now it's wrapped in HOC and Consumer
It cluttered up the server file. Better to use dev tools to slow down the connection (added note to readme)
Relay modern's been around for a while. Don't want to bring old relay sample up to use the new context (not sure it's possible?)
Superseded by react mobile plugin
Hangover from original relay sample
Better to keep samples as primitives than combine two random ones
Wrapped in withStateNavigator HOC like implemented for React plugin
Tried changing to componentWillReceiveProps and it did work, but it was called multiple times. Not sure about this. Anyway, componentWillReceiveProps is deprecated for getDerivedStateFromProps but can't change to this because won't work in old React (and it's called multiple times). When come to do SSR then need it to work with a navigation, first render, so can revisit then
This doesn't work in the React plugin sample!? wonder what the difference is? List isn't the root component here?!
It works with stateNavigator.start before ReactDOM.render. This makes it consistenet with Navigation React. Better to put start first because it has to be first for server side rendering when that comes
Formats better on npm
The infinite loop's fixed with the latest react release
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Backward compatible. The Navigation React tests pass unchanged.
Streamlined Navigation React samples down to 4 primitives. They can be combined together to build a code split, isomorphic relay app, for example.