how to use chrome browser extensions code example

Example: browser extension manager

Functions
browserAction.setTitle()
Sets the browser action's title. This will be displayed in a tooltip.
browserAction.getTitle()
Gets the browser action's title.
browserAction.setIcon()
Sets the browser action's icon.
browserAction.setPopup()
Sets the HTML document to be opened as a popup when the user clicks on the browser action's icon.
browserAction.getPopup()
Gets the HTML document set as the browser action's popup.
browserAction.openPopup()
Open the browser action's popup.
browserAction.setBadgeText()
Sets the browser action's badge text. The badge is displayed on top of the icon.
browserAction.getBadgeText()
Gets the browser action's badge text.
browserAction.setBadgeBackgroundColor()
Sets the badge's background color.
browserAction.getBadgeBackgroundColor()
Gets the badge's background color.
browserAction.setBadgeTextColor()
Sets the badge's text color.
browserAction.getBadgeTextColor()
Gets the badge's text color.
browserAction.enable()
Enables the browser action for a tab. By default, browser actions are enabled for all tabs.
browserAction.disable()
Disables the browser action for a tab, meaning that it cannot be clicked when that tab is active.
browserAction.isEnabled()
Checks whether the browser action is enabled or not.

Tags:

Misc Example