@@ -7,7 +7,6 @@ const firstSnapshotReceived = {};
77// there will be the same number of objects in here as there are reactime tabs open for each user application being worked on
88const tabsObj = { } ;
99
10- console . log ( 'hello from background' ) ;
1110function createTabObj ( title ) {
1211 // update tabsObj
1312 return {
@@ -342,7 +341,7 @@ chrome.runtime.onMessage.addListener((request, sender) => {
342341
343342// when tab is closed, remove the tabid from the tabsObj
344343chrome . tabs . onRemoved . addListener ( ( tabId ) => {
345- console . log ( 'tab is deleted.' ) ;
344+
346345 // tell devtools which tab to delete
347346 if ( portsArr . length > 0 ) {
348347 portsArr . forEach ( ( bg ) =>
@@ -361,7 +360,7 @@ chrome.tabs.onRemoved.addListener((tabId) => {
361360
362361// when a new url is loaded on the same tab, this remove the tabid from the tabsObj, recreate the tab and inject the script
363362chrome . tabs . onUpdated . addListener ( ( tabId , changeInfo ) => {
364- console . log ( 'new site loaded.' ) ;
363+
365364 // check if the tab title changed to see if tab need to restart
366365 if ( changeInfo && tabsObj [ tabId ] ) {
367366 if ( changeInfo . title && changeInfo . title !== tabsObj [ tabId ] . title ) {
@@ -388,7 +387,7 @@ chrome.tabs.onUpdated.addListener((tabId, changeInfo) => {
388387
389388// when tab view is changed, put the tabid as the current tab
390389chrome . tabs . onActivated . addListener ( ( info ) => {
391- console . log ( 'tab view has changed' ) ;
390+
392391 // tell devtools which tab to be the current
393392 if ( portsArr . length > 0 ) {
394393 portsArr . forEach ( ( bg ) =>
@@ -413,7 +412,7 @@ chrome.runtime.onInstalled.addListener(() => {
413412// when context menu is clicked, listen for the menuItemId,
414413// if user clicked on reactime, open the devtools window
415414chrome . contextMenus . onClicked . addListener ( ( { menuItemId } ) => {
416- console . log ( 'inspect clicked reactime' ) ;
415+
417416 const options = {
418417 type : 'panel' ,
419418 left : 0 ,
0 commit comments