chrome.runtime.onInstalled.addListener((details) => {
  console.log("Extension installed");
  if (details.reason === "install") {
    chrome.tabs.create({
      url: "https://travelingtab.com/thanks",
    });
  }
});

chrome.runtime.onMessage.addListener((message, sender, sendResponse) => {
  if (message.action === "search") {
    chrome.search.query({ text: message.query });
  }
});