Skip to content

Commit 44d7257

Browse files
committed
bump: 2.4.0
1 parent c6f7602 commit 44d7257

File tree

4 files changed

+10
-4
lines changed

4 files changed

+10
-4
lines changed

Diff for: lib/docsify.js

+6
Original file line numberDiff line numberDiff line change
@@ -2818,6 +2818,7 @@ var Hook = function Hook () {
28182818
this.afterHooks = [];
28192819
this.initHooks = [];
28202820
this.readyHooks = [];
2821+
this.doneEachHooks = [];
28212822
};
28222823

28232824
Hook.prototype.beforeEach = function beforeEach (fn) {
@@ -2828,6 +2829,10 @@ Hook.prototype.afterEach = function afterEach (fn) {
28282829
this.afterHooks.push(fn);
28292830
};
28302831

2832+
Hook.prototype.doneEach = function doneEach (fn) {
2833+
this.doneEachHooks.push(fn);
2834+
};
2835+
28312836
Hook.prototype.init = function init (fn) {
28322837
this.initHooks.push(fn);
28332838
};
@@ -2991,6 +2996,7 @@ var Docsify = function () {
29912996
mainRender(function (_) {
29922997
scrollIntoView();
29932998
activeLink('nav');
2999+
window.Docsify.hook.emit('doneEach');
29943000
});
29953001
};
29963002

Diff for: lib/docsify.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: lib/plugins/search.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ var install = function () {
290290
new SearchComponent();
291291
!isAuto && searchPlugin();
292292
});
293-
isAuto && hook.beforeEach(searchPlugin);
293+
isAuto && hook.doneEach(searchPlugin);
294294
}, window.$docsify.plugins);
295295
};
296296

Diff for: lib/plugins/search.min.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)