I want to develop a Chrome extension that scrapes data off the page, but this can happen only after all of the pages ajax finish loading their remote content.
Is this possible?
I want to develop a Chrome extension that scrapes data off the page, but this can happen only after all of the pages ajax finish loading their remote content.
Is this possible?
In general, you can't detect when all scripts are finished loading. It is fairly common for a page to wait a couple seconds after the 'onload' event to request an additional round of scripts -- for example, if you want to delay-load ads but don't want to slow down the initial page rendering.
However, extensions do have a flag to run at "document_idle". This flag supposedly makes Chrome wait until the page is "idle" before injected the extension's script. It would not, however wait for a delay-loaded script and it may not even wait for a slow XHR.
More information can be found at http://developer.chrome.com/extensions/content_scripts.html
I think you can't do that, but if you want to check if a particular external script is loaded you can check this: Verify External Script Is Loaded