If you want to know how to pass all other props to react class? You can use the spread operator to pass all other props to react class using reactJS.
1 2 3 4 | const {propOne, propTwo, children, ...props} = this.props; <Component propOne={propOne} propTwo={propTwo} {...props}> {children} </Component> |
If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.