How would I iterate through all tabs a user has open and then check if they have a particular HTML item with id = \'item\'?
id = \'item\'
This is a not deprecated vanilla way (may 2019):
chrome.tabs.query({}, function(tabs){ tabs.forEach(tb => { chrome.tabs.sendMessage(tb.id, { action: "xxx" }); }); });