This commit is contained in:
2017-01-11 20:18:39 +01:00
commit d3f9363380
3 changed files with 30 additions and 0 deletions

0
detecter.js Normal file
View File

11
injecter.js Normal file
View File

@@ -0,0 +1,11 @@
var s = document.createElement('script');
if(window.chrome){
s.src = chrome.extension.getURL('detecter.js');
}else if(browser){
s.src = browser.extension.getURL("detecter.js");
}else{
alert('What kind of browser is this? I don\'t know how to use it!');
}
//todo unload?
(document.head || document.documentElement).appendChild(s);

19
manifest.json Normal file
View File

@@ -0,0 +1,19 @@
{
"manifest_version":2,
"name": "Framework Detector",
"version": "1.0",
"description": "Detect all dem frameworks",
"permissions": ["tabs", "<all_urls>"],
"content_scripts" : [{
"matches" : ["<all_urls>"],
"js" : ["injecter.js"]
}],
"icons": {
"16":"icon16.png",
"48":"icon48.png",
"128":"icon128.png"
},
"web_accessible_resources":[
"detecter.js"
]
}