File tree 2 files changed +11
-13
lines changed
2 files changed +11
-13
lines changed Original file line number Diff line number Diff line change @@ -321,15 +321,15 @@ export function Render(Base) {
321
321
) ;
322
322
}
323
323
324
- this . callHook ( 'afterEach' , html , hookData =>
325
- renderMain . call ( this , hookData )
326
- ) ;
324
+ this . callHook ( 'afterEach' , html , hookData => {
325
+ renderMain . call ( this , hookData ) ;
326
+ next ( ) ;
327
+ } ) ;
327
328
} ;
328
329
329
330
if ( this . isHTML ) {
330
331
html = this . result = text ;
331
332
callback ( ) ;
332
- next ( ) ;
333
333
} else {
334
334
prerenderEmbed (
335
335
{
@@ -339,7 +339,6 @@ export function Render(Base) {
339
339
tokens => {
340
340
html = this . compiler . compile ( tokens ) ;
341
341
callback ( ) ;
342
- next ( ) ;
343
342
}
344
343
) ;
345
344
}
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ test.describe('Plugins', () => {
9
9
'mounted' ,
10
10
'beforeEach-async' ,
11
11
'beforeEach' ,
12
- // 'afterEach-async',
12
+ 'afterEach-async' ,
13
13
'afterEach' ,
14
14
'doneEach' ,
15
15
'ready' ,
@@ -41,13 +41,12 @@ test.describe('Plugins', () => {
41
41
return markdown ;
42
42
} ) ;
43
43
44
- // FIXME: https://github.com/docsifyjs/docsify/issues/449
45
- // hook.afterEach(function (html, next) {
46
- // setTimeout(function () {
47
- // console.log('afterEach-async');
48
- // next(html);
49
- // }, 100);
50
- // });
44
+ hook . afterEach ( function ( html , next ) {
45
+ setTimeout ( function ( ) {
46
+ console . log ( 'afterEach-async' ) ;
47
+ next ( html ) ;
48
+ } , 100 ) ;
49
+ } ) ;
51
50
52
51
hook . afterEach ( function ( html ) {
53
52
console . log ( 'afterEach' ) ;
You can’t perform that action at this time.
0 commit comments