Overview
Provides the following reactive element's size information:
elementHeight- The component's element
$elheight in pixels (integer) elementWidth- The component's element
$elwidth in pixels (integer)
Provided these reactive properties are typically used when the available space is determined by the layout which should influence reponsive behavior of a child component rather than relying on the overall window size.
Usage
import useKResponsiveElement from 'kolibri-design-system/lib/composables/useKResponsiveElement';
export default {
setup() {
const {
elementHeight,
elementWidth,
} = useKResponsiveElement();
}
};
Related
-
See
useKResponsiveWindowif you need the window's size reactive information rather than that of a component