JsExtensionsGetDimensionAsync Method

Asynchronously retrieves the dimensions (width and height) of a specified element.

Definition

Namespace: MobileTrack.Web.Portal.Components.Dashboard.Internal
Assembly: MobileTrack.Web.Portal (in MobileTrack.Web.Portal.exe) Version: 0.7+45c8d9adb5970d727cceec44a5ed61aea0016e50
public static ValueTask<PointF> GetDimensionAsync(
	this IJSRuntime js,
	ElementReference element
)

Parameters

js  IJSRuntime
The JavaScript runtime to invoke the script.
element  ElementReference
The element whose dimensions are to be retrieved.

Return Value

ValueTaskPointF
A tuple representing the width and height of the element.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IJSRuntime. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also