Moved logic to use new file structure
This commit is contained in:
parent
a12c9bae6f
commit
e65dba16b9
3 changed files with 10 additions and 10 deletions
|
@ -1,9 +1,10 @@
|
||||||
var self = require('sdk/self');
|
var self = require('sdk/self');
|
||||||
var pageMod = require("sdk/page-mod");
|
var pageMod = require("sdk/page-mod");
|
||||||
var sites = require("data/site-decoder")
|
var sites = require("data/site-decoder.json")
|
||||||
|
|
||||||
|
|
||||||
|
for (var i = 0; i < sites.length; i++) {
|
||||||
pageMod.PageMod({
|
pageMod.PageMod({
|
||||||
include: "*.facebook.com",
|
include: sites[i][0],
|
||||||
contentScriptFile: ["./jquery.js", "./script.js"]
|
contentScriptFile: ["lib/jquery.js", "./image_lookup.js", "injections/" + sites[i][1]]
|
||||||
});
|
});
|
||||||
|
}
|
|
@ -1,4 +0,0 @@
|
||||||
var site_decoder = { // Site Identifier : Injection JS
|
|
||||||
"*.facebook.com":"facebook.js"
|
|
||||||
}
|
|
||||||
module.exports = site_decoder;
|
|
3
src/site-decoder.json
Normal file
3
src/site-decoder.json
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
{ // Site Identifier : Injection JS
|
||||||
|
"*.facebook.com":"facebook.js",
|
||||||
|
}
|
Reference in a new issue