Getting the following error, even after making the script empty I go this error.
console.error: my-addon:
Message: SyntaxError: expected expression, got end of script
Panel code of my addon:
var { ToggleButton } = require('sdk/ui/button/toggle');
var panels = require("sdk/panel");
var self = require("sdk/self");
var ss = require("sdk/simple-storage");
var button = ToggleButton({
id: "my-addon",
label: "My Addon",
icon: {
"16": "./img/16-16.png",
"32": "./img/32-32.png",
"64": "./img/64-64.png"
},
onChange: handleChange
});
var panel = panels.Panel({
contentURL: self.data.url("popup.html"),
contentScript: self.data.url("js/pop_listener.js"),
onHide: handleHide,
width: 300,
height: 550
});
Use contentScriptFile
instead of contentScript
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With