File tree Expand file tree Collapse file tree 2 files changed +11
-13
lines changed Expand file tree Collapse file tree 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) {
321321 ) ;
322322 }
323323
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+ } ) ;
327328 } ;
328329
329330 if ( this . isHTML ) {
330331 html = this . result = text ;
331332 callback ( ) ;
332- next ( ) ;
333333 } else {
334334 prerenderEmbed (
335335 {
@@ -339,7 +339,6 @@ export function Render(Base) {
339339 tokens => {
340340 html = this . compiler . compile ( tokens ) ;
341341 callback ( ) ;
342- next ( ) ;
343342 }
344343 ) ;
345344 }
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ test.describe('Plugins', () => {
99 'mounted' ,
1010 'beforeEach-async' ,
1111 'beforeEach' ,
12- // 'afterEach-async',
12+ 'afterEach-async' ,
1313 'afterEach' ,
1414 'doneEach' ,
1515 'ready' ,
@@ -41,13 +41,12 @@ test.describe('Plugins', () => {
4141 return markdown ;
4242 } ) ;
4343
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+ } ) ;
5150
5251 hook . afterEach ( function ( html ) {
5352 console . log ( 'afterEach' ) ;
You can’t perform that action at this time.
0 commit comments