DOMContentLoaded和加载事件之间的差异 [英] Difference between DOMContentLoaded and Load events

查看:123
本文介绍了DOMContentLoaded和加载事件之间的差异的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有什么DOMContentLoaded和Load事件之间的区别?

What is the difference between the DOMContentLoaded and the Load event?

推荐答案

的Mozilla开发者中心

在DOMContentLoaded事件时,该文档已被解雇
  完全加载和分析,无需等待样式表,图片,
  和子帧完成加载(Load事件可用于检测
  一个完全加载页)。

The DOMContentLoaded event is fired when the document has been completely loaded and parsed, without waiting for stylesheets, images, and subframes to finish loading (the load event can be used to detect a fully-loaded page).

这篇关于DOMContentLoaded和加载事件之间的差异的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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