M
M
Masterstvo2017-06-01 17:29:22
JavaScript
Masterstvo, 2017-06-01 17:29:22

How to competently build interaction between components in Angular2?

Greetings! I started learning Angular and asked myself this question. Let's say there is a global App component and its child components in it:

<App>
    <Component 1>
    <Component 2>
    <Component 3>
    ...
</App>

What is the best and correct way to set up interaction between components? For example, a bold JSON with data comes into the application. Each component changes this data and changes to this JSON should be reflected in other components. I used React a little, there is such a cool thing as Redux, which stores the state of the application. What about Angular? Interact by means of INPUT or OUTPUT? Should I use Redux for it?
Thank you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
Negwereth, 2017-06-01
@Masterstvo

blog.angular-university.io/angular-2-what-is-unidi...

O
ozknemoy, 2017-06-10
@ozknemoy

IMHO, if you need to use the interaction between adjacent components, the page structure should be rethought. don't get too carried away by breaking everything down into components. then it will be difficult to maintain

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question