found a nasty sync bug that was causing lots of odd issues..

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2022-08-06 01:26:31 +03:00
parent e14c5cab05
commit fd6cf8d7ad
3 changed files with 28 additions and 9 deletions

View File

@ -450,8 +450,9 @@ module.BaseParser = {
this.expand(page, ast, state)
: ast
return ast
// NOTE: we need to await for ast here as we need stage 2 of
// parsing to happen AFTER everything else completes...
return (await ast)
// post handlers...
.map(function(section){
return typeof(section) == 'function' ?

View File

@ -7,6 +7,8 @@
(function(require){ var module={} // make module AMD/node compatible...
/*********************************************************************/
var object = require('ig-object')
var pwiki = require('./pwiki2')
// XXX for some reason this does not run quietly in browser
@ -55,6 +57,27 @@ pwiki.store.update('@pouch', {
// XXX TEST...
// XXX add filter tests...
pwiki.pwiki
.update({
location: '/test/wikiword',
text: object.doc`
This is a basic WikiWord test, all
the [basic] forms and Versions of
/inline/links.
@filter(wikiword markdown) `,
})
.update({
location: '/test/slots',
text: object.doc`
Testing slot mechanics...
This slot is <slot name="empty">unfilled</slot>
...while this <slot name="non-empty">text should be replaced...</slot>
<slot name="non-empty">text is filling a slot</slot>
`,
})
.update({
location: '/test/a',
text: 'a',

View File

@ -1,13 +1,7 @@
/**********************************************************************
*
*
* XXX revise macros...
* - filters behave in an odd way...
* - slots do not seem to work...
* XXX wikiword filter seems to hang on /
* XXX do filters affect the whole page or only what comes after???
* XXX need to be able to affect the default render wrpaper...
* i.e.: /some/path (default) vs. /some/path/_view vs. /some/path/_raw
* XXX wikiword filter seems to act up on /
*
*
* XXX ROADMAP:
@ -28,6 +22,7 @@
* - archive old code
* - update docs
* - refactor and cleanup
* - module structure -- DONE
* - pack as electron app (???)
*
*