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

@asgami-digital/signalfox-react-native

v0.3.11

Published

React Native SDK for SignalFox analytics

Readme

@asgami-digital/signalfox-react-native

SignalFox for React Native is the official client library for instrumenting your app with SignalFox.

It helps you track app lifecycle, native modals, native touchables, navigation, and purchase flows with a simple provider-based setup. It also lets you assign stable signalFoxId values to the UI elements that matter most, so SignalFox can build a consistent understanding of your app structure over time.

Links

  • Website: https://signalfox.io
  • Documentation: https://docs.signalfox.io
  • GitHub: https://github.com/asgami-digital/signalfox-react-native

What This Library Does

Use this library when you want to:

  • initialize SignalFox once at the app root
  • connect your app using your SignalFox API key
  • automatically track app lifecycle events
  • enable tracking for native modals and native touchables at startup
  • add optional integrations such as React Navigation, RevenueCat, or react-native-iap
  • assign stable signalFoxId values to screens, modals, and interactive elements you want SignalFox to understand

Installation

Install the package:

npm install @asgami-digital/signalfox-react-native

or:

yarn add @asgami-digital/signalfox-react-native

If you use optional integrations, install the corresponding packages in your app as needed:

  • @react-navigation/native
  • react-native-purchases
  • react-native-purchases-ui
  • react-native-iap

For iOS, run CocoaPods after installing dependencies:

cd ios && pod install

Quick Start

The basic setup has two steps:

  1. apply the startup patches as early as possible
  2. wrap your app with SignalFoxProvider

1. Apply Startup Patches

Call these patch initializers before your app renders.

They enable tracking for native modals and native touchables.

import {
  applyModalPatch,
  applyTouchablePatch,
} from '@asgami-digital/signalfox-react-native';

applyModalPatch();
applyTouchablePatch();

A common place for this is your app entry file, such as index.js, or a bootstrap module imported from it.

2. Wrap Your App with SignalFoxProvider

Wrap your application with SignalFoxProvider and pass your SignalFox API key.

import React from 'react';
import { SignalFoxProvider } from '@asgami-digital/signalfox-react-native';
import App from './src/App';

export default function Root() {
  return (
    <SignalFoxProvider apiKey="YOUR_SIGNALFOX_API_KEY">
      <App />
    </SignalFoxProvider>
  );
}

Provider Configuration

SignalFoxProvider accepts the following main props:

  • apiKey: your SignalFox API key
  • logOnly: optional boolean for local or debug-only usage
  • integrations: optional array of extra integrations

Basic example:

<SignalFoxProvider apiKey="YOUR_SIGNALFOX_API_KEY">
  <App />
</SignalFoxProvider>

Example with optional integrations:

import Purchases from 'react-native-purchases';
import RevenueCatUI from 'react-native-purchases-ui';
import { navigationRef } from './navigation';

import {
  SignalFoxProvider,
  reactNavigationIntegration,
  revenueCatIntegration,
} from '@asgami-digital/signalfox-react-native';

<SignalFoxProvider
  apiKey="YOUR_SIGNALFOX_API_KEY"
  integrations={[
    reactNavigationIntegration({ navigationRef }),
    revenueCatIntegration({
      purchases: Purchases,
      revenueCatUI: RevenueCatUI,
    }),
  ]}
>
  <App />
</SignalFoxProvider>;

The provider already includes its internal default integrations for app lifecycle, native modals, and native touchables. You do not need to pass those manually.

Optional Integrations

You can extend SignalFox with optional integrations depending on the libraries your app uses.

React Navigation

Use reactNavigationIntegration if your app uses @react-navigation/native.

import {
  SignalFoxProvider,
  reactNavigationIntegration,
} from '@asgami-digital/signalfox-react-native';
import {
  NavigationContainer,
  createNavigationContainerRef,
} from '@react-navigation/native';

const navigationRef = createNavigationContainerRef();

export function Root() {
  return (
    <SignalFoxProvider
      apiKey="YOUR_SIGNALFOX_API_KEY"
      integrations={[reactNavigationIntegration({ navigationRef })]}
    >
      <NavigationContainer ref={navigationRef}>
        {/* app */}
      </NavigationContainer>
    </SignalFoxProvider>
  );
}

RevenueCat

Use revenueCatIntegration if your app uses react-native-purchases.

If you also use react-native-purchases-ui, pass revenueCatUI as well.

import Purchases from 'react-native-purchases';
import RevenueCatUI from 'react-native-purchases-ui';
import {
  SignalFoxProvider,
  revenueCatIntegration,
} from '@asgami-digital/signalfox-react-native';

<SignalFoxProvider
  apiKey="YOUR_SIGNALFOX_API_KEY"
  integrations={[
    revenueCatIntegration({
      purchases: Purchases,
      revenueCatUI: RevenueCatUI,
    }),
  ]}
>
  <App />
</SignalFoxProvider>;

react-native-iap

Use reactNativeIapIntegration if your app uses react-native-iap.

import * as ReactNativeIap from 'react-native-iap';
import {
  SignalFoxProvider,
  reactNativeIapIntegration,
} from '@asgami-digital/signalfox-react-native';

<SignalFoxProvider
  apiKey="YOUR_SIGNALFOX_API_KEY"
  integrations={[
    reactNativeIapIntegration({
      reactNativeIap: ReactNativeIap,
    }),
  ]}
>
  <App />
</SignalFoxProvider>;

signalFoxId Requirements

To make touchable and modal tracking reliable, you must add a unique signalFoxId to every native touchable and every native modal you want SignalFox to track.

A good signalFoxId should be:

  • unique within the app
  • stable over time
  • descriptive enough to identify the UI element or modal purpose

Good examples:

  • checkout-pay-button
  • settings-delete-account-button
  • purchase-paywall-modal
  • profile-edit-photo-button

Avoid:

  • duplicated IDs
  • random values generated on render
  • IDs that change between builds for the same UI element

Touchable Example

<Pressable signalFoxId="checkout-pay-button" onPress={handlePay}>
  <Text>Pay now</Text>
</Pressable>
<TouchableOpacity
  signalFoxId="profile-edit-photo-button"
  onPress={handleEditPhoto}
>
  <Text>Edit photo</Text>
</TouchableOpacity>

Modal Example

<Modal
  visible={isOpen}
  signalFoxId="purchase-paywall-modal"
  onRequestClose={handleClose}
>
  {/* modal content */}
</Modal>

You can also provide signalFoxDisplayName when you want a separate human-readable label, but signalFoxId is the required identifier.

If part of your UI behaves like a modal but does not use the native React Native Modal, you can track it manually with the same modal event family:

import * as SignalFox from '@asgami-digital/signalfox-react-native';

SignalFox.trackModalShown({
  signalfoxId: 'export-sheet',
  displayName: 'Export Sheet',
  visible: true,
});

SignalFox.trackModalShown({
  signalfoxId: 'export-sheet',
  displayName: 'Export Sheet',
  visible: false,
});

When visible is true, SignalFox emits modal_open. When visible is false, it emits modal_close only if that modal is currently present in the modal stack.

Recommended App Startup Shape

A practical setup usually looks like this:

// index.js
import { AppRegistry } from 'react-native';
import {
  applyModalPatch,
  applyTouchablePatch,
} from '@asgami-digital/signalfox-react-native';
import App from './src/App';
import { name as appName } from './app.json';

applyModalPatch();
applyTouchablePatch();

AppRegistry.registerComponent(appName, () => App);
// src/App.tsx
import React from 'react';
import {
  SignalFoxProvider,
  reactNavigationIntegration,
} from '@asgami-digital/signalfox-react-native';
import {
  NavigationContainer,
  createNavigationContainerRef,
} from '@react-navigation/native';

const navigationRef = createNavigationContainerRef();

export default function App() {
  return (
    <SignalFoxProvider
      apiKey="YOUR_SIGNALFOX_API_KEY"
      integrations={[reactNavigationIntegration({ navigationRef })]}
    >
      <NavigationContainer ref={navigationRef}>
        {/* screens */}
      </NavigationContainer>
    </SignalFoxProvider>
  );
}

Public API Used Most Often

Most apps only need:

  • SignalFoxProvider
  • applyModalPatch()
  • applyTouchablePatch()
  • reactNavigationIntegration(...) when using React Navigation
  • revenueCatIntegration(...) when using RevenueCat
  • reactNativeIapIntegration(...) when using react-native-iap

Contributing

License

MIT