Skip to content

Commit e8985a2

Browse files
feat: added router.rendered promise
1 parent 4c2dd1c commit e8985a2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/runtime/Router/Router.js

+5
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,11 @@ export class Router {
108108
(!this.pendingRoute.get() && this.activeRoute.get()) ||
109109
next(this.activeRoute, x => !!x)
110110

111+
rendered = async () => {
112+
await this.ready()
113+
await this.activeRoute.get().rendered
114+
}
115+
111116
/** @type {Map<string, Route>} */
112117
history = new Map()
113118

0 commit comments

Comments
 (0)