react-native-safe-area-context
Version:
A flexible way to handle safe area, also works on Android and web.
24 lines (21 loc) • 543 B
text/typescript
import { TurboModule, TurboModuleRegistry } from 'react-native';
import type { Double } from 'react-native/Libraries/Types/CodegenTypes';
export interface Spec extends TurboModule {
getConstants: () => {
initialWindowMetrics?: {
insets: {
top: Double;
right: Double;
bottom: Double;
left: Double;
};
frame: {
x: Double;
y: Double;
width: Double;
height: Double;
};
};
};
}
export default TurboModuleRegistry.get<Spec>('RNCSafeAreaContext');