diff --git a/polymer-core.html b/polymer-core.html index 96e59d438e..1879611959 100644 --- a/polymer-core.html +++ b/polymer-core.html @@ -58,9 +58,6 @@ } this.listenListeners(); this.listenKeyPresses(); - if (this._useContent) { - this.distributeContent(); - } this.takeAttributes(); } diff --git a/src/features/content.html b/src/features/content.html index b0c56943e0..1fa9118fbe 100644 --- a/src/features/content.html +++ b/src/features/content.html @@ -7,7 +7,16 @@ Code distributed by Google as part of the polymer project is also subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt --> + diff --git a/src/features/ready.html b/src/features/ready.html index 7f81b08a3b..1e09df3d6a 100644 --- a/src/features/ready.html +++ b/src/features/ready.html @@ -79,6 +79,11 @@ _ready: function() { this._readied = true; + // TODO(jmesserly): this is a hook to allow content.html to be called + // before "ready". This needs to be factored better. + if (this._useContent) { + this.distributeContent(); + } this.ready(); }, diff --git a/test/index.html b/test/index.html index 916e64d65a..01c2b2e5a0 100644 --- a/test/index.html +++ b/test/index.html @@ -18,6 +18,7 @@ WCT.loadSuites([ 'unit/base.html', 'unit/ready.html', + 'unit/content.html' ]); diff --git a/test/unit/content.html b/test/unit/content.html new file mode 100644 index 0000000000..7d491e19c8 --- /dev/null +++ b/test/unit/content.html @@ -0,0 +1,383 @@ + + + + + + + + + + + + + +