blob: 5e6b22bea59ee778b94ed19369aa0d8b40dd9086 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// General JavaScript
require ("./js/general")();
// Page-specific JavaScript
const pageName = document.getElementsByTagName("body")[0].id;
try {
require("./js/" + pageName)();
} catch (error) {
console.log(
"Something went wrong when loading the js for this page...\n" +
"The pageName is \"" + pageName + "\".\n" +
"If it was excpected to get js for this page, please check the filename, and recompile webpack."
);
}
// Require all styles
require("./app.scss");
|