Skip to content
Browse files

Use `_clientsReadied` to avoid missing attribute->property sets in re…

…ady.
  • Loading branch information...
1 parent b269c1d commit 165f7164091e9d2bb7f16aa54e2167869f45e8bb @sorvell sorvell committed
Showing with 13 additions and 2 deletions.
  1. +1 −1 src/standard/configure.html
  2. +11 −1 test/unit/attributes-elements.html
  3. +1 −0 test/unit/attributes.html
View
2 src/standard/configure.html
@@ -61,7 +61,7 @@
},
_attributeChangedImpl: function(name) {
- var model = this._readied ? this : this._config;
+ var model = this._clientsReadied ? this : this._config;
this._setAttributeToProperty(model, name);
},
View
12 test/unit/attributes-elements.html
@@ -139,9 +139,19 @@
</dom-module>
<script>
Polymer({
+
+ is: 'x-compose',
+
hostAttributes: {
attr1: 'compose'
},
- is: 'x-compose'
+
+ properties: {
+ prop2: String
+ },
+
+ ready: function() {
+ this.setAttribute('prop2', 'hi');
+ }
});
</script>
View
1 test/unit/attributes.html
@@ -284,6 +284,7 @@
assert.strictEqual(compose.$.basic.prop, 'compose');
assert.equal(compose.$.basic.propChangedCount, 1);
assert.equal(compose.$.basic.attr1ChangedCount, 1);
+ assert.equal(compose.prop2, 'hi');
});
});

0 comments on commit 165f716

Please sign in to comment.
Something went wrong with that request. Please try again.