Jun 24
Help: My script is using jQuery and is not working under Scriptify!
I've encountered a strange error when I bundled a well-working Userscript with Scriptify into a Firefox Extension:
The summary: this is not a Scriptify issue!
The verbose explanation:
My userscript was using the @require marker to use jQuery and it's matching engine to do some of it's magic. Problem was - as soon as my Javascript code reached jQuery's $() it silently stopped! After much digging, it turned out that upon bundling, Scriptify has downloaded jQuery for inclusion into the package, faciliating the Firefox zip creation engine, but this Firefox lib is currently (hopefully fixed soon) exposing a rare bug that will cause the file being added truncated. So if you are experiencing problems with a script that uses @require or an external script, make sure this script has ended up complete in Scriptify. In my case, about a third of code were missing from jQuery's source. To solve that, just manually imported the require'd script into the bundle.