MediaQueryList

A MediaQueryList object stores information on a media query applied to a document, with support for both immediate and event-driven matching against the state of the document.

MDN Reference

Properties

Link copied to clipboard
external val matches: Boolean

The matches read-only property of the MediaQueryList interface is a boolean value that returns true if the document currently matches the media query list, or false if not.

Link copied to clipboard
external val media: MediaQuery

The media read-only property of the MediaQueryList interface is a string representing a serialized media query.

Functions

Link copied to clipboard
open external fun dispatchEvent(event: Event): Boolean
Link copied to clipboard
external fun <T : Event> when(type: EventType<T>, options: ObservableEventListenerOptions?): Observable<T>