1
0
Fork 0

maybe saari work?

This commit is contained in:
Z 2021-06-13 21:11:01 +01:00
parent be8e363de2
commit cea21b266f
2 changed files with 5 additions and 6 deletions

View file

@ -42,7 +42,7 @@
"webpack": "^5.38.1",
"webpack-cli": "^4.7.0",
"webpack-dev-server": "^3.11.2",
"z-pagerouter": "^1.0.5"
"z-pagerouter": "^1.0.6"
},
"dependencies": {
"css-minimizer-webpack-plugin": "^3.0.0"

View file

@ -52,15 +52,14 @@ async function onLoad(): Promise<void> {
pageTitleElement: document.querySelector("#pageTitle"),
pageContentElement: document.querySelector("#pageContent"),
resetElementContent: !true,
onPageChanged: async function (_) {
pageState.currentPage = await pageRouter.getCurrentPageID();
document.documentElement.dir = pageState.pageDirection;
},
});
reloadNavBar(pageRouter);
pageRouter.addEventListener("pageChanged", async function (_) {
pageState.currentPage = await pageRouter.getCurrentPageID();
document.documentElement.dir = pageState.pageDirection;
});
if (process.env.NODE_ENV == "development") {
await playground(pageRouter);
}