4 days ago there was an announcement that js-ctypes is banned.
You will have to use native messaging.
Pros of NativeMessaging
- MUCH MUCH easier, no need to declare all the type definitions and signatures of methods.
- Cross browser - you can start selling your addons and make your pocket win - Google Chrome and Edge is where the market is at.
- Its unreviewed by AMO staff - developer can do whatever you want to
Cons
- Major major limitation (ctypes did not have this issue) - many platform APIs must run in the target process.
- Major limitation of no Android support
- Requires “installation” even if we just need a 1kb exe that has a single function. Even if you place the exe within the extension it has no affect. You have to deliver it from a 3rd party source in an installer. This introduces major friction with users on the ease of use, discover-ability fronts.
- Unreviewed which leads to:
- Users will not trust it, and will be afraid to download it
- Reduces AMO integrity, as it puts on users un-reviewed material
I would say really check out Native Messaging, it’s pretty great if you ignore the cons. Here is a demo:
If you need help let me know I can step you through it. I was a total newbie to this and struggled through, I hope to help others avoid that struggle.