npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@nfsmonstr/react-native-splash-screen

v5.0.0

Published

A splash screen for react-native, hide when application loaded, it works on iOS and Android. Reworked fork of https://github.com/crazycodeboy/react-native-splash-screen.git

Readme

@nfsmonstr/react-native-splash-screen

A splash screen library for React Native using TurboModules (New Architecture).

Works on iOS (UIKit window overlay) and Android (AndroidX SplashScreen API).

Reworked fork of crazycodeboy/react-native-splash-screen — original library by Jia PengHui.


Requirements

| | Minimum | |---|---| | React Native | 0.73+ (New Architecture) | | iOS | 13.0+ | | Android | API 24+ |


Installation

npm install @nfsmonstr/react-native-splash-screen
# or
yarn add @nfsmonstr/react-native-splash-screen

Android Setup

1. Update styles.xml

android/app/src/main/res/values/styles.xml

<resources>
    <!-- Splash screen theme — must inherit Theme.SplashScreen -->
    <style name="SplashTheme" parent="Theme.SplashScreen">

        <!-- ─── Required ──────────────────────────────────────────────────── -->

        <!-- Background color of the entire splash screen -->
        <item name="windowSplashScreenBackground">@color/splashBackground</item>

        <!-- Theme applied to the Activity after the splash exits.
             Must NOT inherit from Theme.SplashScreen. -->
        <item name="postSplashScreenTheme">@style/AppTheme</item>

        <!-- ─── Icon ──────────────────────────────────────────────────────── -->

        <!-- Center icon. Recommended size: 240×240dp (visible area: 160×160dp).
             Supports PNG, VectorDrawable, or AnimatedVectorDrawable. -->
        <item name="windowSplashScreenAnimatedIcon">@drawable/splash_icon</item>

        <!-- Background color shown behind the icon (useful when the icon
             has transparent areas or uses a non-circular shape).
             Default: transparent. -->
        <item name="windowSplashScreenIconBackgroundColor">@color/splashIconBackground</item>

        <!-- Duration of the icon animation in milliseconds.
             Only meaningful when windowSplashScreenAnimatedIcon is an
             AnimatedVectorDrawable. Maximum value: 1000ms.
             Default: 0 (no animation). -->
        <item name="windowSplashScreenAnimationDuration">500</item>

        <!-- ─── Branding ───────────────────────────────────────────────────── -->

        <!-- Branding image displayed at the bottom of the splash screen.
             Typically a company logo. Use a horizontal PNG or VectorDrawable.
             Shown on API 31+ (Android 12+); silently ignored on older versions. -->
        <item name="windowSplashScreenBrandingImage">@drawable/splash_branding</item>

    </style>

    <!-- The actual app theme, applied after the splash screen exits -->
    <style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
        <item name="android:editTextBackground">@drawable/rn_edit_text_material</item>
    </style>
</resources>

android/app/src/main/res/values/colors.xml (create if it doesn't exist)

<?xml version="1.0" encoding="utf-8"?>
<resources>
    <color name="splashBackground">#FFFFFF</color>
    <!-- Optional: background behind the icon -->
    <color name="splashIconBackground">#FFFFFF</color>
</resources>

2. Update AndroidManifest.xml

Set SplashTheme as the application theme:

android/app/src/main/AndroidManifest.xml

<application
  ...
  android:theme="@style/SplashTheme">

Icon size guide

The splash screen icon is placed inside a circular mask (following the adaptive icon spec):

| Zone | Size | |---|---| | Full icon canvas | 240 × 240 dp | | Safe area (always visible) | 160 × 160 dp | | Masked outer ring | 40 dp on each side |

Keep your logo within the 160 × 160 dp safe area. The outer 40 dp may be clipped on some devices.

3. Wire up MainActivity

Add a single call to ReactNativeSplashScreenModule.show(this) before super.onCreate():

import android.os.Bundle
import com.facebook.react.ReactActivity
import com.facebook.react.ReactActivityDelegate
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.fabricEnabled
import com.facebook.react.defaults.DefaultReactActivityDelegate
import com.nfsmonstr.reactnativesplashscreen.ReactNativeSplashScreenModule

class MainActivity : ReactActivity() {

  override fun onCreate(savedInstanceState: Bundle?) {
    ReactNativeSplashScreenModule.show(this) // must be before super!
    super.onCreate(savedInstanceState)
  }

  override fun getMainComponentName(): String = "YourAppName"

  override fun createReactActivityDelegate(): ReactActivityDelegate =
      DefaultReactActivityDelegate(this, mainComponentName, fabricEnabled)
}

Why before super.onCreate()? The AndroidX SplashScreen API requires installSplashScreen() to be called before the Activity's super.onCreate(). The library handles this internally.


iOS Setup

1. Call show() from AppDelegate

Swift

import ReactNativeSplashScreen

func application(
  _ application: UIApplication,
  didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
) -> Bool {
  // Show the splash screen overlay before React Native initializes
  ReactNativeSplashScreen.show()

  // ... rest of your setup
  return true
}

Objective-C

#import <ReactNativeSplashScreen/ReactNativeSplashScreen.h>

- (BOOL)application:(UIApplication *)application
    didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
  [ReactNativeSplashScreen show];
  // ...
}

2. LaunchScreen.storyboard

The library automatically reads your app's existing LaunchScreen.storyboard — no additional assets or configuration needed. The overlay creates a seamless continuation of the system launch image.


JavaScript Usage

import SplashScreen from '@nfsmonstr/react-native-splash-screen';

// In your root component:
useEffect(() => {
  async function init() {
    await loadUserSession(); // your async initialization
    SplashScreen.hide();
  }
  init();
}, []);

API

| Method | iOS | Android | Description | |---|:---:|:---:|---| | SplashScreen.hide() | ✓ | ✓ | Dismisses the splash screen with a fade animation | | SplashScreen.show() | ✓ | — | Shows the splash screen overlay (iOS only; no-op on Android) |


How It Works

Android

Uses the AndroidX SplashScreen API (androidx.core:core-splashscreen). The system displays the splash before the Activity renders. ReactNativeSplashScreenModule.show(this) calls installSplashScreen() and sets a keep-visible condition. When SplashScreen.hide() is called from JavaScript, the condition is cleared and the system animates the splash out.

iOS

Displays a UIWindow overlay loaded from your app's LaunchScreen.storyboard, at UIWindowLevel above the main window. The overlay is shown before React Native loads and is dismissed with a 250ms fade animation when SplashScreen.hide() is called.


Contributing

See CONTRIBUTING.md.


License

MIT


Credits

Original library created by Jia PengHui (crazycodeboy)github.com/crazycodeboy/react-native-splash-screen

Reworked for New Architecture (TurboModules) by NFS_MONSTR