I am developing a chrome extension for fetching ads from a web page. What I am trying to do is that:
- My extension should look for HTML5 banner ads from the opened web page.
- It should detach the ad code and save it to my computer as an html file.
- The html file created should not depend on an external JS or CSS file. It means when it gets detached, the CSS or JS code attached to it should be detached and saved as a part of the html page (not a hyper link).
I was wondering if there are any existing libraries or open source plugins that do that. If not, can anyone point me in the right direction where to begin?