loadend 事件总是在一个资源的加载进度停止之后被触发 (例如,在已经触发“error”,“abort”或“load”事件之后)。这适用于 XMLHttpRequest 调用,以及 <img><video> 之类元素的内容。

General info


Property Type Description
target 只读 EventTarget The event target (the topmost target in the DOM tree).
type 只读 DOMString The type of event.
bubbles 只读 Boolean Whether the event normally bubbles or not.
cancelable 只读 Boolean Whether the event is cancellable or not.
lengthComputable 只读 Boolean Specifies whether or not the total size of the transfer is known. Read only.
loaded 只读 unsigned long (long) The number of bytes transferred since the beginning of the operation. This doesn't include headers and other overhead, but only the content itself. Read only.
total 只读 unsigned long (long) The total number of bytes of content that will be transferred during the operation. If the total size is unknown, this value is zero. Read only.


XMLHttpRequest Standard
# event-xhr-loadend
XMLHttpRequest Standard
# handler-xhr-onloadend