Skip to content
This repository has been archived by the owner on Dec 17, 2021. It is now read-only.

Latest commit

 

History

History
14 lines (9 loc) · 897 Bytes

readasync.md

File metadata and controls

14 lines (9 loc) · 897 Bytes

CSS/readAsync()

This function returns one or more style properties for the given element. It is a convenient alternative to window.getComputedStyle. It also has special support for vendor-prefixed properties.

The suffix Async differentiates this method from its Sync counterpart - readSync(). Unlike the Sync counterpart, readAsync() is a promised-based function that runs in a different flow from that of the calling code. It follows a performance strategy that lets the browser engine decide the most convenient time to honour its call.

Import

import readAsync from '@web-native-js/play-ui/src/css/readAsync.js';

Syntax

See cssAsync() - Get Computed Properties