element-size

Get the size of an element in pixels, including margins

OTHER License

Downloads
810.3K
Stars
13
Committers
1

element-size stable

Get the size of an element in pixels, including margins

Usage

[width, height] = size(element)

Given a DOM element, return an array containing that element's width and height in pixels.

License

MIT. See LICENSE.md for details.