useKeplerWindowDimensionsV2 use this hook instead which updates the dimensions based
on root tag to handle multiple interactive component and multiple instances
Dimensions.get('window'). If you have more than one application component you will need to
use Dimensions.get('windows') and identify the dimensions for the particular component you are interested in.
When there is more than one Vega app component, Dimensions.get(‘window’) returns dimensions for the first component
created in the app process.
If you are targeting foldable devices or devices which can change the screen size or app window size, you can use the event listener available in the Dimensions module as shown in the following example.
Example Vega
Reference
Methods
addEventListener()
change: Fires when a property within theDimensionsobject changes. The argument to the event handler is aDimensionsValuetype object.
get()
runApplication is called so they should be available before any other require’s are run, but may be updated later.
Example: const {height, width} = Dimensions.get('window');
Vega example:

