mirror of
https://github.com/kkapsner/CanvasBlocker
synced 2025-07-03 20:16:33 +02:00
Cleanup require system
This commit is contained in:
parent
11b8ddfcc8
commit
574efa23e7
35 changed files with 45 additions and 67 deletions
|
@ -9,8 +9,7 @@
|
|||
scope = exports;
|
||||
}
|
||||
else {
|
||||
scope = {};
|
||||
window.scope.optionsGui = scope;
|
||||
scope = require.register("./optionsGui", {});
|
||||
}
|
||||
|
||||
const logging = require("./logging");
|
||||
|
|
|
@ -9,8 +9,7 @@
|
|||
scope = exports;
|
||||
}
|
||||
else {
|
||||
scope = {};
|
||||
window.scope.sanitationRules = scope;
|
||||
scope = require.register("./sanitationRules", {});
|
||||
}
|
||||
|
||||
const settings = require("./settings");
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
"use strict";
|
||||
|
||||
const settings = require("./settings");
|
||||
const sanitationRules = require("./sanitationRules");
|
||||
|
||||
var title = document.createElement("h1");
|
||||
title.className = "title";
|
||||
|
@ -18,7 +19,6 @@
|
|||
|
||||
settings.onloaded(function(){
|
||||
const list = document.createElement("ul");
|
||||
const sanitationRules = require("./sanitationRules");
|
||||
sanitationRules.ruleset.forEach(function(ruleset){
|
||||
const rulesetContainer = document.createElement("li");
|
||||
rulesetContainer.textContent = browser.i18n.getMessage("sanitation_ruleset." + ruleset.name);
|
||||
|
|
|
@ -545,6 +545,6 @@
|
|||
module.exports = settingsDisplay;
|
||||
}
|
||||
else {
|
||||
window.scope.settingsDisplay = settingsDisplay;
|
||||
require.register("./settingsDisplay", settingsDisplay);
|
||||
}
|
||||
}());
|
Loading…
Add table
Add a link
Reference in a new issue