react-navigation / rfcs

RFCs for changes to React Navigation
Other
88 stars 16 forks source link

navigation.navigate prop params should match signature of NavigationActions.navigate params #52

Closed lfkwtz closed 6 years ago

lfkwtz commented 6 years ago

Not sure if this has been brought up before, but what's the logic in having different param signatures between the two?

navigation.navigate('sampleRoute', {sampleParam: 'hello'})

vs.

NavigationActions.navigate({
    routeName: 'sampleRoute',
    params: {sampleParam: 'hello'},
})
brentvatne commented 6 years ago

the reason is that the helper is more concise