cleanup...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2022-05-11 15:36:35 +03:00
parent 9c986b553f
commit 3e0281b920

View File

@ -1648,7 +1648,16 @@ var WIKIWORD_PATTERN =
//--------------------------------------------------------------------- //---------------------------------------------------------------------
// XXX experiments and testing... // Basic setup...
//
//
// Store popology:
//
// root (BaseStore) ---next--- main (MetaStore)
// |
// +-- System/... (BaseStore)
//
//
var store = var store =
module.store = module.store =
@ -1705,19 +1714,15 @@ var System = {
// XXX nested system store... // XXX nested system store...
store.update('System', Object.create(BaseStore).load(System)) store.update('System', Object.create(BaseStore).load(System))
/*/ // XXX chained system store... /*/ // XXX chained system store...
store.next.load(
// Create a new system action-set with paths starting with 'System/' // Create a new system action-set with paths starting with 'System/'
var RootSystem =
Object.entries(System) Object.entries(System)
.reduce(function(res, [key, func]){ .reduce(function(res, [key, func]){
res[module.path.join('System', key)] = func res[module.path.join('System', key)] = func
return res }, {}) return res }, {}))
store.next.load(RootSystem)
//*/ //*/
store.load(require('./bootstrap'))
// NOTE: in general the root wiki api is simply a page instance. // NOTE: in general the root wiki api is simply a page instance.
// XXX not yet sure how to organize the actual client -- UI, hooks, .. etc // XXX not yet sure how to organize the actual client -- UI, hooks, .. etc
var pwiki = var pwiki =
@ -1726,6 +1731,12 @@ Page('/', '/', store)
//---------------------------------------------------------------------
// XXX experiments and testing...
store.load(require('./bootstrap'))
// XXX TEST... // XXX TEST...
// XXX add filter tests... // XXX add filter tests...
console.log('loading test page...') console.log('loading test page...')