https://kotlinlang.org logo
Title
g

GauthierPLM

12/20/2017, 12:50 PM
Is there any kotlin wrapper around the browser API to build extensions?
g

gildor

12/20/2017, 4:30 PM
k

kirillrakhman

12/20/2017, 4:32 PM
g

gildor

12/20/2017, 4:34 PM
Yes, I mean there is no official ones, that why I reference your article :) I'm also curious about Chrome extension declaration, could your generator be reused for chrome
👍 1
k

kirillrakhman

12/21/2017, 8:19 AM
It most certainly could be reused. the chrome declarations can be found here: https://chromium.googlesource.com/chromium/src/+/master/chrome/common/extensions/api but many apis are the same except that the root object is called
chrome
, not
browser
. extensions that target both browsers can use a polyfill, something like https://github.com/kee-org/browser-addon/blob/bad6039589ac2b0b9af5af7cf435008d316b5983/common/browser-polyfill.js