Browse Source

Load props from props registry for redux screens

Guy Carmeli 7 years ago
parent
commit
2c27564ef3
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      src/Navigation.js

+ 2
- 2
src/Navigation.js View File

@@ -67,13 +67,13 @@ function _registerComponentRedux(screenID, generator, store, Provider, options)
67 67
       constructor(props) {
68 68
         super(props);
69 69
         this.state = {
70
-          internalProps: {...props, ...PropRegistry.load(props.screenInstanceID)}
70
+          internalProps: {...props, ...PropRegistry.load(props.screenInstanceID || props.passPropsKey)}
71 71
         }
72 72
       }
73 73
 
74 74
       componentWillReceiveProps(nextProps) {
75 75
         this.setState({
76
-          internalProps: {...PropRegistry.load(this.props.screenInstanceID), ...nextProps}
76
+          internalProps: {...PropRegistry.load(this.props.screenInstanceID || this.props.passPropsKey), ...nextProps}
77 77
         })
78 78
       }
79 79