jQuery UI Widgets › Forums › General Discussions › Plugins › Data Adapter › Clean up DOM after data reload
Tagged: calendar, data adapter, dataBind, DOM, element, grid, html, jqxCalendar, jqxDataAdapter, jqxgrid, update
This topic contains 5 replies, has 2 voices, and was last updated by Dimitar 10 years, 6 months ago.
-
Author
-
Hi,
I have an issue with detached DOM nodes.
When I perform a source update, the amounf of DOM nodes added to the DOM tree appears to be about the same amount of nodes as when initially loading the Grid. As if a brand new Grid is created, and the old one is never removed.Code example:
jqxData.source.localdata = data.items; jqxData.adapter.dataBind();Is there some sort of method – other than
destroy– that I can call to clean up old/unused/detached DOM nodes?Regards,
MarcusHi Marcus,
We tested the following example: http://jsfiddle.net/Dimitar_jQWidgets/h76bxu1j/ and experience no such issue while observing the DOM with Chrome Developer Tools. Please make sure you are using the latest version of jQWidgets (3.8.0).
Best Regards,
DimitarjQWidgets team
http://www.jqwidgets.com/Hi again,
I was unspecific in my previous post.
The increase in DOM nodes is tied to.databind()and widgets.Using your example, I essentially just added the
jqxDateTimeInputwidget to the ‘firstname’ field: http://jsfiddle.net/h76bxu1j/1/So, if you simply press the “Update bounded data” button, you should be able to observe the increase of DOM nodes with an id starting with
calendarjqxWidget. Every time you press the button, it adds another<div id="calendarjqxWidget....
Imagine if you have several widgets…Is this a known issue?
Regards,
MarcusHi Marcus,
Thank you for your feedback. We confirm this issue and have created a work item about it.
Best Regards,
DimitarjQWidgets team
http://www.jqwidgets.com/Thank you,
Do you think it is something that will be fixed before, and included in, the next release?Regards,
MarcusHi Marcus,
I am not sure this will be possible, but we will try our best. Once the issue has been fixed, you will be able to find out in the Release History.
Best Regards,
DimitarjQWidgets team
http://www.jqwidgets.com/ -
AuthorPosts
You must be logged in to reply to this topic.