Repository navigation
Conversation
|
You can preview 802d257 at https://pr26316-802d257.ngbuilds.io/. |
|
You can preview 3f26161 at https://pr26316-3f26161.ngbuilds.io/. |
mhevery
approved these changes
Oct 9, 2018
Contributor
Author
Contributor
Author
|
@jasonaden AIO local test keeps flaking, so I can't get this green Update: green now |
jasonaden
pushed a commit
that referenced
this pull request
Oct 9, 2018
pkozlowski-opensource
added a commit
to pkozlowski-opensource/angular
that referenced
this pull request
Oct 10, 2018
It was removed in angular#26316
mhevery
pushed a commit
that referenced
this pull request
Oct 11, 2018
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR flattens the
LViewData[DIRECTIVES]array intoLViewDataand theTView.directivesarray intoTView.data. This reduces memory pressure by avoiding the creation of unnecessary nested arrays. It also implements the host binding algorithm outlined inVIEW_DATA.md.Notes:
loadDirective()was being used inhostBindingandcontentQueriesfunctions as a special instruction to read from thedirectivesarray. Now that there isn't adirectivesarray, we can simply use the existingload()instruction in these cases, so theloadDirective()instruction has been removed.loadDirective()in a number of places as a testing utility. This can't really be replaced withload()because now that directives are flat, it's harder to predict where the directive will live inviewData(e.g. there might be other directives with injectors and host bindings ahead of it), so I've created a new testing utility to replace it calledgetDirectiveOnNode(). This takes the node index and an optional directive offset.ElementRef. This is unnecessary given that they are created using factories, so injecting these tokens no longer triggers the creation of an injector on its own.For more information about this change, see
VIEW_DATA.md.