0

How can is check chrome extension is installed or not , when extension is disabled ?

I found that when extension is disabled we can not access the background.js and also its icon.png or manifest.json.

3 Answers3

1

While the extension is disabled, both the background script and the content script are alive, but the communication medium is disabled. So you can't send messages between them.

Can be captured using

chrome.runtime.connect().onDisconnect.addListener(function(e) {});

In the worst case, you can do a POST message.

SherylHohman
  • 16,580
  • 17
  • 88
  • 94
0

If a extension is disabled, any code in it would not work, so it is not possible to get the installation status from a disabled extension

gscHeartA
  • 44
  • 4
0

You can capture using

chrome.runtime.connect().onDisconnect.addListener(function(e) {

    ...

});
Hasip Timurtas
  • 983
  • 2
  • 11
  • 20