Updating main JS to not run if not on the index page
This is to get the karma tests in a position where they can be written
This commit is contained in:
parent
8651fd0d9b
commit
dbae70ce52
@ -2,6 +2,8 @@ import Regexper from './regexper.js';
|
||||
|
||||
(function() {
|
||||
var regexper = new Regexper(document.body);
|
||||
|
||||
if (document.body.querySelector('#content')) {
|
||||
regexper.bindListeners();
|
||||
|
||||
setTimeout(() => {
|
||||
@ -10,4 +12,5 @@ import Regexper from './regexper.js';
|
||||
evt.initEvent('hashchange', true, true);
|
||||
window.dispatchEvent(evt);
|
||||
});
|
||||
}
|
||||
}());
|
||||
|
Loading…
Reference in New Issue
Block a user