From 8f7300006ed896f829145d717a5d5a7d17296eed Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Wed, 8 Feb 2023 02:07:31 +0300 Subject: [PATCH] notes and cleanup... Signed-off-by: Alex A. Naanou --- pwiki/parser.js | 5 ----- pwiki2.html | 5 +++-- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/pwiki/parser.js b/pwiki/parser.js index 82a9895..ffee6d7 100755 --- a/pwiki/parser.js +++ b/pwiki/parser.js @@ -489,9 +489,6 @@ module.BaseParser = { return {...value, skip: true} } // macro call... return Promise.awaitOrRun( - // XXX due to the unpredictable behavior of await we - // need to call this only AFTER the previous call - // is done... that.callMacro(page, name, args, body, state), function(res){ res = res ?? '' @@ -501,8 +498,6 @@ module.BaseParser = { return res } else { return [res] } }) }, - // XXX BUG: this is not called on errors in: - // file:///L:/work/pWiki/pwiki2.html#/Tests/ParseErrorOutputTest function(err){ console.error(err) return page.parse( diff --git a/pwiki2.html b/pwiki2.html index 0609409..6297388 100755 --- a/pwiki2.html +++ b/pwiki2.html @@ -296,6 +296,7 @@ var updateStyle = async function(){ //*/ // XXX might be a good idea to make this a method of pwiki??? +// XXX the page seems to be broken... var CONFIG_UPDATED = false var updateConfig = async function(){ // XXX need to set this to something... @@ -449,11 +450,11 @@ require(['./browser'], function(browser){ if(STYLE_UPDATED){ STYLE_UPDATED = false await updateStyle() } - //*/ // config... if(CONFIG_UPDATED){ CONFIG_UPDATED = false await updateConfig() } + //*/ // NOTE: we are intentionally not awaiting for this -- this // separates the navigate and load events... logTime( @@ -510,7 +511,7 @@ require(['./browser'], function(browser){ // setup global stuff... // XXX GLOBAL_STYLE //updateStyle() - updateConfig() + //updateConfig() // show current page... pwiki.location = decodeURI(location.hash).slice(1) }) })