怎样快捷获取网页的window对象

使用document.defaultView;

document.defaultView === window

注意: 

1. 如果当前文档不属于window对象, 则返回null;

2. document.defaulView 是 document 的快捷方式属性;

猜你喜欢

转载自www.cnblogs.com/aisowe/p/11531196.html
今日推荐