延迟 jquery 脚本,直到其他所有内容都已加载 [英] Delaying a jquery script until everything else has loaded

查看:29
本文介绍了延迟 jquery 脚本,直到其他所有内容都已加载的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 jquery 脚本,我只需要在页面上的其他所有内容(包括其他一些 javascript(我无法控制)完成它们的操作后运行它.

I have a jquery script which I need to run only once everything else on the page, including some other javascripts (over which I have no control) have finished doing their thing.

我虽然可能有 $(document).ready 的替代方法,但我一直找不到它.

I though perhaps there was an alternative to $(document).ready but I haven't been able to find it.

推荐答案

事实证明,由于 javascript 框架的特殊混合,我需要使用其他框架之一提供的事件侦听器来启动脚本.

It turns out that because of a peculiar mixture of javascript frameworks that I needed to initiate the script using an event listener provide by one of the other frameworks.

这篇关于延迟 jquery 脚本,直到其他所有内容都已加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆