Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Get the current tab

//// background.js

async function getCurrentTab() {
  let queryOptions = { active: true, currentWindow: true };
  let [tab] = await chrome.tabs.query(queryOptions);
  return tab;
}
Source by developer.chrome.com #
 
PREVIOUS NEXT
Tagged: #Get #current #tab
ADD COMMENT
Topic
Name
3+3 =