
Security News
Static vs. Runtime Reachability: Insights from Latio’s On the Record Podcast
The Latio podcast explores how static and runtime reachability help teams prioritize exploitable vulnerabilities and streamline AppSec workflows.
react-native-is-edge-to-edge
Advanced tools
Many libraries provide options to account for the transparency of status and navigation bars. For example, the useHideAnimation
hook in react-native-bootsplash
includes statusBarTranslucent
and navigationBarTranslucent
options, while the useAnimatedKeyboard
hook in react-native-reanimated
offers an isStatusBarTranslucentAndroid
option, among others.
[!IMPORTANT]
Until third-party libraries officially add support forreact-native-edge-to-edge
to set these options automatically, you may need to adjust them manually to prevent interference with the library.
To support library authors, we provide this lightweight package called react-native-is-edge-to-edge
(note the -is-
!), which checks whether react-native-edge-to-edge
is installed, making it easier to update your library accordingly:
import {
controlEdgeToEdgeValues,
isEdgeToEdge,
} from "react-native-is-edge-to-edge";
const EDGE_TO_EDGE = isEdgeToEdge();
function MyAwesomeLibraryComponent({
statusBarTranslucent,
navigationBarTranslucent,
}) {
if (__DEV__) {
// warn the user once about unnecessary defined values
controlEdgeToEdgeValues({
statusBarTranslucent,
navigationBarTranslucent,
});
}
return (
<MyAwesomeLibraryNativeComponent
statusBarTranslucent={EDGE_TO_EDGE || statusBarTranslucent}
navigationBarTranslucent={EDGE_TO_EDGE || navigationBarTranslucent}
// …
/>
);
}
If you want to check for the library's presence on the native side to bypass certain parts of your code, consider using this small utility:
object EdgeToEdge {
// we cannot detect edge-to-edge, but we can detect react-native-edge-to-edge install
val ENABLED: Boolean = try {
Class.forName("com.zoontek.rnedgetoedge.EdgeToEdgePackage")
true
} catch (exception: ClassNotFoundException) {
false
}
}
FAQs
Detect react-native-edge-to-edge package install
The npm package react-native-is-edge-to-edge receives a total of 1,539,948 weekly downloads. As such, react-native-is-edge-to-edge popularity was classified as popular.
We found that react-native-is-edge-to-edge demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The Latio podcast explores how static and runtime reachability help teams prioritize exploitable vulnerabilities and streamline AppSec workflows.
Security News
The latest Opengrep releases add Apex scanning, precision rule tuning, and performance gains for open source static code analysis.
Security News
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.