English, asked by suvosarkar1634, 1 year ago

What is the best scope to be used for reusable directives

Answers

Answered by aqsaahmed19945
0

Answer:

Parent scope

Explanation:

In AngularJS, the child scope ordinarily prototypically acquires from its parent scope. One exemption to this standard is an order/directive that utilizes scope: { ... } - this makes a "confine" scope that does not prototypically inherit.(and mandate with transclusion) This build is regularly utilized while making a "reusable part" order. In directives, the parent degree is utilized straightforwardly as a matter of course, which implies that whatever you change in your mandate that originates from the parent scope will likewise change in the parent scope. In the event that you set scope: true (rather than a degree: { ... }), at that point prototypical legacy will be utilized for that mandate.

Similar questions