跳转到主要内容

Document: defaultView property

{{APIRef("DOM")}}

In browsers, document.defaultView returns the {{domxref("Window", "window")}}window object associated with {{Glossary("Browsing_context", "a document")}}document, or null if none is available.

This property is read-only.

Value

The {{domxref("Window", "window")}}window object.

Specifications

{{Specifications}}

Browser compatibility

{{Compat}}