Gets the height of hidden objects by temporarily revealing them and processing.

Parameters:
NameTypeDescription
elHTMLElement

The hidden element to get height for.

Since
  • 1.0.0
Returns:

The height in pixels as number for the hidden element.

Type: 
number
Example
import { getHiddenHeight } from  "@gravityforms/utils";

function Example() {
 const node = document.getElementById( 'hidden-example' );
 const height = getHiddenHeight( node );
}