Update index.html
Browse files- index.html +1 -16
index.html
CHANGED
|
@@ -9,21 +9,6 @@
|
|
| 9 |
<body>
|
| 10 |
<div id="app"></div>
|
| 11 |
|
| 12 |
-
<
|
| 13 |
-
const params = new URLSearchParams(window.location.search);
|
| 14 |
-
const view = params.get("view") || "home";
|
| 15 |
-
|
| 16 |
-
fetch(view + ".html")
|
| 17 |
-
.then(res => {
|
| 18 |
-
if (!res.ok) throw new Error("Page not found");
|
| 19 |
-
return res.text();
|
| 20 |
-
})
|
| 21 |
-
.then(html => {
|
| 22 |
-
document.getElementById("app").innerHTML = html;
|
| 23 |
-
})
|
| 24 |
-
.catch(() => {
|
| 25 |
-
document.getElementById("app").innerHTML = "<h1>Page not found</h1>";
|
| 26 |
-
});
|
| 27 |
-
</script>
|
| 28 |
</body>
|
| 29 |
</html>
|
|
|
|
| 9 |
<body>
|
| 10 |
<div id="app"></div>
|
| 11 |
|
| 12 |
+
<hr> Hello </hr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
</body>
|
| 14 |
</html>
|