javascript - How to display Polymer dialog -


i'm trying started google's polymer paper elements 1.0 displaying simple message dialog:

<html> <head>    <script src="scripts/polymer/webcomponentsjs/webcomponents.min.js"></script> </head> <body>  <paper-dialog opened="true">dialog test</paper-dialog>  </body> </html> 

the words "dialog test" appear on page, there's no dialog. know i'm missing?

you missing reference paper-dialog element definition.

<html>     <head>         <title>example</title>         <script src="path/to/webcomponentsjs/webcomponents-lite.js"></script>         <link rel="import" href="path/to/paper-dialog/paper-dialog.html" />     </head>     <body>         <paper-dialog opened="true">dialog test</paper-dialog>     </body> </html> 

including proper import (<link rel="import" href="path/to/paper-dialog/paper-dialog.html" />) allow element recognized browser , provide functionality expect including behavior , style.

for interactive tutorial on using web components can check out tutorial on component.kitchen.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -