Add popup that allows modifying the config url

This commit is contained in:
Dave Gallant
2023-04-08 00:04:33 -04:00
parent 5a58a92460
commit c72db40f7d
13 changed files with 262 additions and 31 deletions

View File

@@ -1,18 +1,8 @@
function updateRedirects() {
var URL =
"https://raw.githubusercontent.com/davegallant/rfd-redirect-stripper/main/redirects.json";
fetch(URL)
.then((res) => res.json())
.then((res) => {
chrome.storage.local.set({
"rfd-redirects": res,
});
});
}
importScripts('utils.js');
chrome.runtime.onInstalled.addListener(() => {
updateRedirects();
setDefaultConfig();
});
setInterval(updateRedirects, 1 * 60 * 60 * 1000);