As I understand it, you want to edit a specific DOM fragment to your satisfaction before displaying it , for example, "Manipulate the DOMs that are currently displayed".
I would rather suggest making a workaround for this, which I use several times for a similar purpose.
- First append the div / element and immediately hide it .
- There, after you can edit it in any way.
- Do any editing / CSS application / DOM Manip and then display the element or delete it if you just want to get data from this.
- TA-dah!
EDIT To solve the problem of possible flashing, you can do one more thing.
- create an empty DIV and hide it (hiding an empty div may not cause blinking, because it will happen very quickly)
- Then add the DOM object you want (while it is hidden)
- then show your mercy about it.
let me know if I misunderstood your problem.
source share