Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question for converting Firefox addon to Chomium extension #80

Closed
mikhoul opened this issue Apr 6, 2018 · 1 comment
Closed

Question for converting Firefox addon to Chomium extension #80

mikhoul opened this issue Apr 6, 2018 · 1 comment

Comments

@mikhoul
Copy link

mikhoul commented Apr 6, 2018

I'm migrating to Chromium from Firefox but I have some addons that use promise that I'd like to convert.

Those addons like this one use promise and so they return errors like this: https://i.imgur.com/H8UYYFY.png

What would be the most easy way (since I'm not really fluent with JS) to convert them, would it be by loading the polyfill.js script from the manifest.json and adding something like that in the beginning of the .js files of the addon ??

var browser = new polyfill();

Regards :octocat:

@taylorhakes
Copy link
Owner

Unfortunately browser is not a Promise javascript object. It is a Javascript object specific to Firefox, so this library can't be of any help.

Here are the docs on the firefox version
https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/storage
and for Chrome
https://developer.chrome.com/apps/storage

You need to translate to the Chrome version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants