@@ -125,7 +125,7 @@ The short answer is that compile and link separation is needed any time a change
125125a change in DOM structure such as in repeaters.
126126
127127When the above example is compiled, the compiler visits every node and looks for directives. The
128- `{{user}}` is an example of {@link api/ng.$interpolate interpolation} directive. {@link
128+ `{{user}}` is an example of an {@link api/ng.$interpolate interpolation} directive. {@link
129129api/ng.directive:ngRepeat ngRepeat} is another directive. But {@link
130130api/ng.directive:ngRepeat ngRepeat} has a dilemma. It needs to be
131131able to quickly stamp out new `li`s for every `action` in `user.actions`. This means that it needs
@@ -138,16 +138,16 @@ But compiling on every `li` element clone would be slow, since the compilation r
138138traverse the DOM tree and look for directives and execute them. If we put the compilation inside a
139139repeater which needs to unroll 100 items we would quickly run into performance problems.
140140
141- The solution is to break the compilation process into two phases the compile phase where all of
141+ The solution is to break the compilation process into two phases; the compile phase where all of
142142the directives are identified and sorted by priority, and a linking phase where any work which
143143links a specific instance of the {@link api/ng.$rootScope.Scope scope} and the specific
144144instance of an `li` is performed.
145145
146146{@link api/ng.directive:ngRepeat ngRepeat} works by preventing the
147- compilation process form descending into `li` element. Instead the {@link
147+ compilation process form descending into the `li` element. Instead the {@link
148148api/ng.directive:ngRepeat ngRepeat} directive compiles `li`
149149separately. The result of of the `li` element compilation is a linking function which contains all
150- of the directives contained in the `li` element ready to be attached to a specific clone of `li`
150+ of the directives contained in the `li` element, ready to be attached to a specific clone of the `li`
151151element. At runtime the {@link api/ng.directive:ngRepeat ngRepeat}
152152watches the expression and as items are added to the array it clones the `li` element, creates a
153153new {@link api/ng.$rootScope.Scope scope} for the cloned `li` element and calls the
0 commit comments