如何绕过导航时的DOMContentLoaded

嘿,

如果你在寻找页面加载时触发的事件,可以使用 api.onPageChange

api.onPageChange((url, title) => {
   console.log('the page changed to: ' + url + ' and title ' + title);
});

如果你在寻找其他东西,能否详细说明一下你想实现什么?我们可以给你一个更精确的答案。

顺便说一句,你有很多文档可能对你有帮助:https://meta.discourse.org/c/documentation/developer-guides。

3 个赞