expo / ex-navigation

Route-centric navigation for React Native
997 stars 201 forks source link

withNavigation on stateless components does not work. add withRef option #447

Closed chirag04 closed 7 years ago

chirag04 commented 7 years ago

withNavigation right now sets a ref on wrappedComponent which can be a stateless function. This causes a warning in react 16. This PR adds a withRef option to withNavigation. This is a breaking change but i doubt anyone is using this.

chirag04 commented 7 years ago

cc @skevy @brentvatne @janicduplessis