@
@
@Richswitch2018-07-01 16:20:30
JavaScript
@Richswitch, 2018-07-01 16:20:30

How to pass data from child component to parent using Redux?

Hey!
Still looking for a way to avoid using callback functions or bubbling to pass state from child component to parent.
There is a form

<form className="create-event" onSubmit={this.handleOnSubmit}>
        <div className="form-body">
          <Provider store={store}>
            <CreateEventFormBody />
          </Provider>
        </div>
    </form>

Inside this form, there are many fields, some of which form an array of data, and I want to send this data to the parent using the event onSubmit. I was advised to use Redux and at first I thought it would help me, but in the end I never found a built-in method in Redux that would shoot data up, except for callback functions and bubbling.
Is there something similar in Redux?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question