Skip to content

Commit

Permalink
fix: update StackActions.popToTop type to make options arg optional (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
OzzieOrca authored and satya164 committed Jun 4, 2019
1 parent 6563277 commit 35625de
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion flow/react-navigation.js
Expand Up @@ -882,7 +882,8 @@ declare module 'react-navigation' {
n?: number,
immediate?: boolean,
}) => NavigationPopAction,
popToTop: (payload: {
popToTop: (payload?: {
key?: string,
immediate?: boolean,
}) => NavigationPopToTopAction,
push: (payload: {
Expand Down
2 changes: 1 addition & 1 deletion typescript/react-navigation.d.ts
Expand Up @@ -1226,7 +1226,7 @@ declare module 'react-navigation' {

function pop(options: NavigationPopActionPayload): NavigationPopAction;
function popToTop(
options: NavigationPopToTopActionPayload
options?: NavigationPopToTopActionPayload
): NavigationPopToTopAction;

function push(options: NavigationPushActionPayload): NavigationPushAction;
Expand Down

0 comments on commit 35625de

Please sign in to comment.