One still gains access to a rudimentary from of "relatedNode" on onNodeInserted however this event doesn't fire for every single node either. I've been able to modify innerHTML using this node previously in something although that's certainly not a recommended approach it seems to have instant results during load.
I was hoping that supporting doc-start many people would try to use this technique and perhaps things will become more accessible as they are loading in future specs. I think using GM_addStyle will be the best way to prevent flicker although there might be some other possibilities. Whenever it's time to more forward with this I can probably help out a little bit more, I don't think the latest revision is working properly but we had a version that worked well in everything but still has not been tested in FF4. On Sun, Oct 17, 2010 at 2:43 PM, Anthony Lieuallen <[email protected]>wrote: > On 10/17/2010 3:52 AM, Giorgos Tzampanakis wrote: > >> I'm writing some scripts to eliminate annoying elements from websites, by >> finding them using their id and then removing them. My problem is that >> the removed elements are first loaded, drawn on the screen and then >> removed. Is it possible to eliminate elements before they are drawn? >> > > Today, with Greasemonkey: no. There is 100% agreement that running scripts > earlier would be nice, and there has been some recent promising work in that > direction. > > Even if it were done though, javascript still would not be able to > accomplish this. In order to find the elements by ID, they must be first > loaded. The closest you can come is: > http://wiki.greasespot.net/DOMContentLoaded#Flicker > IMO it's not worth the effort. Or, if it's always literally an ID (or via > an other reliable CSS selector), you can simply rely on user styles to force > them to never show, with no need for a script at all. > > > -- > You received this message because you are subscribed to the Google Groups > "greasemonkey-users" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<greasemonkey-users%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/greasemonkey-users?hl=en. > > -- You received this message because you are subscribed to the Google Groups "greasemonkey-users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/greasemonkey-users?hl=en.
