开发者

How to get calculated element width and height in YUI3?

开发者 https://www.devze.com 2023-01-03 15:50 出处:网络
jQuery has handy .height() and .width() utilities to get calculated displayed size of a DOM element. It also has .position() to get coordinates. In YUI3 Node, I see that there are .getX(), .getY() and

jQuery has handy .height() and .width() utilities to get calculated displayed size of a DOM element. It also has .position() to get coordinates. In YUI3 Node, I see that there are .getX(), .getY() and .getXY() utilities to get 开发者_如何学Pythonposition, but I do not see anything for size (or can't look).

What's a good way to get element height and width in YUI3?


getComputedStyle

.getComputedStyle("width")
.getComputedStyle("height")
0

精彩评论

暂无评论...
验证码 换一张
取 消