![I want to pass props of a component to another and Props need to be dynamic depending on which button is clicked. I have created an illustration to ask question properly. Thanks : I want to pass props of a component to another and Props need to be dynamic depending on which button is clicked. I have created an illustration to ask question properly. Thanks :](https://preview.redd.it/i-want-to-pass-props-of-a-component-to-another-and-props-v0-ynkskwokjhd91.jpg?width=640&crop=smart&auto=webp&s=5d261cfed17eff0409853a49431c5593f8034af1)
I want to pass props of a component to another and Props need to be dynamic depending on which button is clicked. I have created an illustration to ask question properly. Thanks :
![How to Pass All Props to a Child Component in React | by Dr. Derek Austin 🥳 | Coding at Dawn | Medium How to Pass All Props to a Child Component in React | by Dr. Derek Austin 🥳 | Coding at Dawn | Medium](https://miro.medium.com/v2/resize:fit:1400/1*TdJiBcxhfoFyrAHeJtal-Q.png)
How to Pass All Props to a Child Component in React | by Dr. Derek Austin 🥳 | Coding at Dawn | Medium
![javascript - While passing props to class component returns undefined. No problem with passing to the function component though - Stack Overflow javascript - While passing props to class component returns undefined. No problem with passing to the function component though - Stack Overflow](https://i.stack.imgur.com/cRXoy.png)