Skip to content

Instantly share code, notes, and snippets.

@dance2die dance2die/popup.js
Last active Feb 17, 2019

What would you like to do?
{ active: true, windowId: },
function(tabs) {
const { id: tabId } = tabs[0].url;
let code = `document.querySelector('h1')`;
chrome.tabs.executeScript(tabId, { code }, function (result) {
// result has the return value from `code`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.