Thanks Daniel On Wednesday, July 5, 2017 at 7:14:25 PM UTC-5, Daniel Llewellyn wrote: > > > > On 6 July 2017 at 01:08, Daniel Llewellyn <[email protected] > <javascript:>> wrote: >> >> <dom-bind id="app"> >> <my-app name="[[temp]]"></my-app> >> </dom-bind> >> >> <script> >> var app = document.getElementById("app"); >> app.temp = localStorage.getItem("saved"); >> </script> >> > > Oops, I also bound the array directly to the string-requiring field in > this first example. You probably want to use something like the _getAnItem > function from the second example in the example above. (the function is > below) > > >> // add _getAnItem() function to return something meaningful - you need >> a string, but the example you provided in temp holds an array. >> app._getAnItem = function(arr) { >> return arr[0].name; >> } >> > > > -- > Daniel Llewellyn > Bowl Hat >
Follow Polymer on Google+: plus.google.com/107187849809354688692 --- You received this message because you are subscribed to the Google Groups "Polymer" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/c3d49471-337c-4122-bc43-685114de731b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
