Here I am working with chrome extension development.
my manifest.json page as show
{
"name": "DemoExtension",
"version": "1.0",
"description": "Official addon from demeo",
"browser_action": {
"default_icon": "star-on.png",
"popup": "shopcmp.htm"
},
"permissions": [
"tabs"
],
"background_page": "background.html"
}
Here I want to change my default icon image at runtime.
If you want to change the browser action default icon, just change
That line indicates the default icon on first load of the extension.
To change the icon in code, call
chrome.browserAction.setIcon(details).If you want to change the extension icon (the icons that shows during installation, in the Chrome Web Store, in the extension management page, and as a favicon), add an
iconsproperty to your manifest.json file.