Rechercher dans l’assistance

Évitez les escroqueries à l’assistance. Nous ne vous demanderons jamais d’appeler ou d’envoyer un SMS à un numéro de téléphone ou de partager des informations personnelles. Veuillez signaler toute activité suspecte en utilisant l’option « Signaler un abus ».

Learn More

How to detect if WebExtension is installed?

  • 3 réponses
  • 2 ont ce problème
  • 6 vues
  • Dernière réponse par Alixandir

more options

I'm developing a firefox add on, using the new web extension mechanism. Now I need to check in my web page if the extension is installed. I know that in chrome you have: chrome-extension://nnhadaeaehpngjcegobbnogakdapkiph/{your content} Is there something like that in firefox? Is there an alternative way?



Toutes les réponses (3)

more options

hi ofer, for developement related questions it's best to ask in the official addon forum at since there will be more mozilla staff from the addons team and other devs reading along there...

more options
more options

The best way is to add any class or data attribute to body or another part of DOM in case if you have content script. Also you can use sendMessage API and ask extension about status.

I hope that Mozilla team will support chrome method to request is extension installed.

But for now - little DOM modification the best way to deal with it :) And "has" cross browsers support.