Skip to content

Commit a8b8055

Browse files
author
Arthur Evans
committed
Merge pull request Polymer#574 from h0ru5/patch-1
added heads-up for Polymer/polymer#677
2 parents 3796442 + 573f86d commit a8b8055

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

docs/polymer/styling.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,9 @@ The veiling process can be used to prevent FOUC at times other than page load. T
6565
<link rel="stylesheet" href="my-element.css">
6666
...
6767
</template>
68+
<script>
69+
Polymer('my-element',...);
70+
</script>
6871
</polymer>
6972

7073
{{site.project_title}} will automatically inline the `my-element.css` stylesheet using a `<style>`:
@@ -74,8 +77,13 @@ The veiling process can be used to prevent FOUC at times other than page load. T
7477
<style>.../* Styles from my-element.css */...</style>
7578
...
7679
</template>
80+
<script>
81+
Polymer('my-element',...);
82+
</script>
7783
</polymer>
7884

85+
Be careful to put the stylesheet inside the template. We recommend putting the `<script>` tag below the template, especially if you include a stylesheet, however note this is optional otherwise.
86+
7987
## Polyfill CSS selectors {#directives}
8088

8189
When running under the Shadow DOM polyfill, {{site.project_title}} provides special `polyfill-*`

0 commit comments

Comments
 (0)