Answer the question
In order to leave comments, you need to log in
How to write directives (components) that interact with each other?
There is such an example in the documentation https://docs.angularjs.org/guide/directive (section "Creating Directives that Communicate")
In this example, the directives in the house tree are placed "one inside the other", in my case the house directive trees do not intersect .
Case: There is a grid with a table inside, rows in the grid can be added and removed by controls inside the block, but it should be possible to move controls to an arbitrary place on the page
. Should this be done in directives or is a component enough?
I plan to make the grid a component and put the creation of the grid object into a factory, in the same factory there will be a method that returns an already created grid with string management methods.
There can be several grids on the page, and for some I put out controls and for some I don’t, which is why I plan to use a factory.
Answer the question
In order to leave comments, you need to log in
In this example, the directives in the house tree are placed "one inside the other", in my case, the house trees of the directives do not intersect.
Take an angular course at codeacademy. There, among other things, the creation of directives is being worked out
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question