-Поиск по дневнику

Поиск сообщений в rss_planet_mozilla

 -Подписка по e-mail

 

 -Постоянные читатели

 -Статистика

Статистика LiveInternet.ru: показано количество хитов и посетителей
Создан: 19.06.2007
Записей:
Комментариев:
Написано: 7


Jorge Villalobos: Porting a Chrome extension to WebExtensions in half a step

Вторник, 29 Марта 2016 г. 02:09 + в цитатник

A coworker contacted me today about the Unbias Me extension. It’s a set of simple userscripts that hide profile pictures and names in sites like LinkedIn and GitHub, where unconscious bias can affect your behavior toward women and other groups. She wanted to know if we could have an add-on like this for Firefox.

I gave the add-on a quick look and realized it would be trivial to port it to WebExtensions. WebExtensions already support browser_action and content_scripts, which is what the add-on uses. So, ultimately all I needed to do was add a little bit of metadata:

  "applications": {
    "gecko": {
      "id": "unbias-me@fureigh",
        "strict_min_version": "45.0"
    }
  },

That’s it! You just zip the files together and use the .xpi file extension, and you’re good to go. Here’s the unsigned XPI if you want to give it a try. I sent a PR to the developer, so I hope they can integrate this code and get the add-on listed on our site.

This may seem like an unfair example since content scripts are the simplest form of add-on. However, keep in mind that they’re also the most common form of add-on. Having support for this API means that there are probably thousands of Chrome extensions that can be very easily ported right now to work with release versions of Firefox and to be listed on AMO. If there’s a Chrome extension you would like to see ported to Firefox, you should give this little experiment a try.

http://xulforge.com/blog/2016/03/porting-a-chrome-extension-to-webextensions-in-half-a-step/


 

Добавить комментарий:
Текст комментария: смайлики

Проверка орфографии: (найти ошибки)

Прикрепить картинку:

 Переводить URL в ссылку
 Подписаться на комментарии
 Подписать картинку