function onGot(color) {
console.log(color);
}
function onFailure(error) {
console.log(error);
}
browser.action.getBadgeBackgroundColor({}).then(onGot, onFailure);action.getBadgeBackgroundColor() / notebook
action.getBadgeBackgroundColor()
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.