Skip to content

Commit

Permalink
created placeholder for talking over across service
Browse files Browse the repository at this point in the history
  • Loading branch information
Thiti-Dev committed Mar 18, 2023
1 parent 8369376 commit d489429
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions chrome-extension/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
chrome.tabs.onZoomChange.addListener((ZoomChangeInfo) => {
console.log(`Zoom level changed to ${ZoomChangeInfo.newZoomFactor}`);

const data = {
query: 'my search query string',
};

fetch('http://localhost:3000/api/search-receive', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify(data),
})
.then((response) => {
console.log('Sending search query to tracker service with status:', response.status);
})
.catch((error) => console.error('Error:', error));
});

0 comments on commit d489429

Please sign in to comment.