This works for me in both Chrome and Firefox on OS X with
the  'webcomponents-lite.js'

Thanks for solving this.



On Thu, Oct 6, 2016 at 2:11 PM, 'Rupert Smith' via Elm Discuss <
[email protected]> wrote:

> On Thursday, October 6, 2016 at 12:07:15 PM UTC+1, Rupert Smith wrote:
>>
>> On Thursday, October 6, 2016 at 11:50:01 AM UTC+1, Rupert Smith wrote:
>>>
>>> On Thursday, October 6, 2016 at 11:14:46 AM UTC+1, Peter Damoc wrote:
>>>>
>>>> Custom elements also work decently when the custom element takes no
>>>> children but if it does, it stops working.
>>>>
>>>
>>> Rendering of keyed nodes in the vdom is here:
>>>
>>> https://github.com/elm-lang/virtual-dom/blob/master/src/Nati
>>> ve/VirtualDom.js#L382
>>>
>>> I will try attaching a debug break point there and see if that yields
>>> any insights.
>>>
>>
>> Ok, got it working. I needed to add some global config to polymer like
>> this:
>>
>>     <script src="bower_components/webcomponentsjs/webcomponents-lite.js"
>> ></script>
>>     <script>
>>         window.Polymer = {
>>             dom: 'shadow',
>>             lazyRegister: true
>>         };
>>     </script>
>>
>> As described here:
>>
>> https://www.polymer-project.org/1.0/docs/devguide/settings
>>
>> This was just a guess, I have not played around with different values of
>> the settings, e.g., lazyRegister true/false. But at least the child
>> elements are not dissappearing.
>>
>
> I think this will also necessitate using 'webcomponents.js' instead of
> 'webcomponents-lite.js' for browsers other than Chrome, as the former
> includes the shadow dom polyfill. Actually, I am prepared to be surprised
> if this works outside of chrome...
>
> https://www.polymer-project.org/1.0/docs/browsers
>
> --
> You received this message because you are subscribed to the Google Groups
> "Elm Discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>



-- 
There is NO FATE, we are the creators.
blog: http://damoc.ro/

-- 
You received this message because you are subscribed to the Google Groups "Elm 
Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to