score:3
Accepted answer
To simplify the solution you can do something like this:
<BigText onChange={data => {this.setState({ data })}} />
In the BigText component then you can put some data via this callback like this:
handleInputChange(event) {
const data = {
[event.target.name]: event.target.value
};
this.setState(data );
this.props.onChange(data);
}
And transfer this data to your BigTextMobile component from state:
<BigTextMobile data={this.state.data} ... />
Source: stackoverflow.com
Related Query
- How to pass data from one component to another in React or React-Redux?
- how to pass the data from one component to another in react js
- How to pass data from one component to another component in onchange using React js
- React - How can I pass API data from one component to another in a different js file?
- How to pass data from one component to another component/parent in React
- How to pass json data from one component to another using functions in react
- How to pass data from one component to another ReactJS
- How to pass data from one component to another while using API in reactjs
- How to refresh data of one component from another component in react js
- Passing data from one component to another - React & Redux
- React | pass form data from one component to another
- How to fetch data from API and then pass it to another component in react after it is fully loaded?
- How to pass a Json data from one folder to another folder in react
- How to pass a prop from one component to another when using react router link
- How to pass data from one variable in props to another in React app?
- How to pass data from one component to another via a function in ReactJS?
- How can I pass props from one component to another using Link and router in react
- how to pass data from one container to another container in react router
- How to pass state from one component to another in React js?
- How to transfer data from one parent component to another parent component in react using router / router params
- How to pass data received from a database as props to another component in react
- How do I pass data from one sibling to another using React Router?
- How to pass array as result from one functional component to another in React
- React Redux - Pass data from state to another component to display list of results
- How to pass props onClick from one component to another in React JS
- How to send data from one react component to another react component?
- React couldn't pass a data from one class component into another using Link
- How to pass data from one React website to another React Website
- How can I pass props from one component to another withour Redux
- How can i pass data from one component to another using hooks
More Query from same tag
- Can't capture the form's submit event in a React app
- How to fill in a table in react with an array of objects?
- flask-socketio stucks after multiple connections
- Function always performs action on last mapped object rather than the one i choose while in Modal
- How to dynamically add class to parent div of focused input field?
- Declaring JSX element as child
- Get dynamically data from an object in React
- Error: Final loader (./node_modules/awesome-typescript-loader/dist/entry.js) didn't return a Buffer or String
- React: Why is it necessary to have immutable props if values are passed as by value anyway?
- Parameter 'initialState' cannot be referenced in its initializer
- react-redux useCallback infinite render
- How does Redux Reselect memoization work?
- Cannot read property 'todos' of undefined ReactJs,Redux
- responsive buttongroup buttons in material ui + reactjs app
- how to hide a button in particular condition?
- Can't set global state from reduxForm to local state
- Error in function createFiberrFromTypeAndProps
- How to import mulitple variables or list from another component in React JS?
- SecurityError: The operation is insecure - React Heroku
- Why is react react-hooks/exhaustive-deps changing my code?
- (React Hooks) Ref method not updating state value
- TypeError: Cannot read property 'state' of undefined - function
- react doesn't render components with changes even when state changes
- Can't take screenshot of hovered element in Cypress
- How can I destructure react query async return variables so that one of them doesn't log undefined?
- Trouble posting to MongoDB with axios
- What is the best approach for calling third-party react hooks conditionally?
- Problem on handling array of object as state
- How can I render data within nested objects in react?
- React continuously rendering when calling useEffect dependency