-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove dirty checks for objects #3596
Closed
Closed
Conversation
This file contains 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
Note: `this[property] = value` implicitly guards against setting read onlys. This check is now explicit.
Note: `set`'s third argument is unused within the library and should be removed. Note: No readOnly check here, why? Note: Additional dirty check in accessors.html redundant. Obvious code duplication between annotation effect and annotation path- effect. Merge both?
Also opens `set` to set read-only properties. Note: computed properties could be set as well. Nobody should do this.
That's harsh, but 1. set() is a public method, so +1 for clean interface 2. totally not used within the framework Actually I think it was never used. For the record: could have been used to set a path without notifying. (There is an equivalent arg for `_get` which is used though during config.)
Removes _pathEffector override completely. Replaces _notifyPathUp override.
Avoid dirty checking values, instead use a lock.
This reduces the addiction to dirty check values.
The general rule here is: `_forwardParentProp/Path` must assume fromAbove is true; for `_forwardInstanceProp/Path` assume fromAbove is false.
…-checks-for-objects
…-checks-for-objects
…or-objects # Conflicts: # src/standard/notify-path.html
…ty-checks-for-objects # Conflicts: # src/lib/bind/accessors.html
…for-objects # Conflicts: # src/lib/bind/accessors.html # src/standard/notify-path.html # test/unit/bind-elements.html # test/unit/bind.html
I think we should have these API changes/additions:
whereby |
@kaste I see that many of your ideas, this one included, made their way into the implementation of v2. Just wanted to say thanks! |
As @devinivy pointed out your suggestions have been adopted and are available in Polymer 2 as the MutableData mixin. Thanks! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
To come to an end here. Assembles the following PRs:
Then we can just remove the dirty check for object values 6d24b87.
Related #3343.