We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 44c64ee commit 3a6df85Copy full SHA for 3a6df85
src/firebaseConnect.js
@@ -92,10 +92,14 @@ export const createFirebaseConnect = (storeKey = 'store') => (
92
}
93
94
render() {
95
- // Prevent internal refs from being passed down to children
96
- let props = { ...this.props }
97
- delete props._firebaseRef
98
- delete props._dispatch
+ // Prevent reserved props from being passed down to children
+ let props = Object.keys(this.props).reduce((acc, p) => {
+ if (RESERVED_PROPS.indexOf(p) === -1) {
+ acc[p] = this.props[p]
99
+ }
100
+ return acc
101
+ }, {})
102
+
103
return <WrappedComponent {...props} />
104
105
0 commit comments