[Dojo-interest] Relation between widget and DOM

W.S. Hager wshager at gmail.com
Thu Jun 19 12:58:47 EDT 2014


Well I'm interested in the following: when destroying a widget but leaving
the DOM node intact, would it be considered bad practice to create a new
widget on the old DOM node?

For instance, I want a Tree at the same place in the DOM where there had
been a ContentPane (i.e. in the same LayoutContainer). The widget is
destroyed, but the DOM stays intact:
- removeChild is NOT called
- the child is destroyed with preserveDom
- the root node is emptied
- the child is removed from the registry
- a new child is instantiated with root node as its target

I should think that there is no (formal) objection to doing that, right?


2014-06-19 18:42 GMT+02:00 Karl Tiedt <ktiedt at gmail.com>:

> Well, it's hard to have a widget without dom... so I'd say it's a
> relationship borne of necessity... widgets are visual enhancements
> generally speaking and that requires dom...
>
> Not sure what else you could say about it...
> On Jun 19, 2014 11:15 AM, "W.S. Hager" <wshager at gmail.com> wrote:
>
>> No I meant does the relation have a formal basis like XBL, or was it just
>> developed by some dojo developers.
>>
>>
>> 2014-06-19 18:10 GMT+02:00 Karl Tiedt <ktiedt at gmail.com>:
>>
>>> Generally speaking widgets extends the functionality of the dom node
>>> they reference in some way... And often they replace that node with a more
>>> complex template that comes from the widget to enable these enhanced
>>> features.
>>> On Jun 19, 2014 10:00 AM, "W.S. Hager" <wshager at gmail.com> wrote:
>>>
>>>>  Hi,
>>>>
>>>> Can anybody tell me the (formal) relationship between widgets and the
>>>> DOM? Is there any formal basis or did this simply emerge from
>>>> implementation choices historically?
>>>>
>>>> How is this different in for instance web components?
>>>>
>>>> Thanks.
>>>> Wouter
>>>>
>>>> --
>>>> Dojo Toolkit: http://dojotoolkit.org/
>>>> Tutorials: http://dojotoolkit.org/documentation/
>>>>
>>>> Dojo-interest at mail.dojotoolkit.org
>>>> To unsubscribe, visit:
>>>> http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest
>>>>
>>>>
>>> --
>>> Dojo Toolkit: http://dojotoolkit.org/
>>> Tutorials: http://dojotoolkit.org/documentation/
>>>
>>> Dojo-interest at mail.dojotoolkit.org
>>> To unsubscribe, visit:
>>> http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest
>>>
>>>
>>
>>
>> --
>>
>> W.S. Hager
>> Lagua Web Solutions
>> http://lagua.nl
>>
>> --
>> Dojo Toolkit: http://dojotoolkit.org/
>> Tutorials: http://dojotoolkit.org/documentation/
>>
>> Dojo-interest at mail.dojotoolkit.org
>> To unsubscribe, visit:
>> http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest
>>
>>
> --
> Dojo Toolkit: http://dojotoolkit.org/
> Tutorials: http://dojotoolkit.org/documentation/
>
> Dojo-interest at mail.dojotoolkit.org
> To unsubscribe, visit:
> http://mail.dojotoolkit.org/mailman/listinfo/dojo-interest
>
>


-- 

W.S. Hager
Lagua Web Solutions
http://lagua.nl
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.dojotoolkit.org/pipermail/dojo-interest/attachments/20140619/a8b523b6/attachment.htm 


More information about the Dojo-interest mailing list