0

I have written a code to check whenever a user installs a chrome extension from my website but I am not getting it to work. See code below:

if(chrome.app.isInstalled){
    alert("installed");
}
else{
    alert("not_installed");
}

Can anyone assist?

Chelseawillrecover
  • 2,596
  • 1
  • 31
  • 51
nch7
  • 110
  • 2
  • 7
  • Are you installing using `chrome.webstore.install`? If so, just define a callback function. See docs - https://developer.chrome.com/extensions/webstore.html#method-install – Rob W Dec 15 '13 at 14:04
  • Thanks for help Rob, I managed to make this work with callback functions :) – nch7 Dec 15 '13 at 14:47
  • @Rob This will no longer work as of chrome 71. `window.chrome.webstore` is now `undefined` – Esteban Dec 05 '18 at 20:17

0 Answers0