Skip to content

Repository files navigation

@limelink/react-native

React Native bridge for LimeLink deep links, universal/app links, analytics, and deferred deep links on Android and iOS.

Support

  • Install floor: React Native 0.81 with React 19.1+
  • New Architecture through legacy-module interoperability
  • Hermes (Legacy Architecture and JSC are unsupported)
  • Community CLI and Expo Development Builds (expo-dev-client)
  • Android API 24+
  • iOS 12+

This package is not a direct TurboModule. The verification matrix records minimum RN 0.81.5 Android Debug/Release and clean iOS pod installation plus simulator Debug/Release passing with Xcode 16.4. RN 0.85 Community, RN 0.86 Expo Development Builds, and RN 0.86.2 packed-tarball checks provide additional New Architecture interoperability evidence. Expo Go and web are not supported.

Wrapper 1.0.1 specifically passed current Community CLI Android Debug Java bridge compilation and iOS simulator Debug with native dependencies 1.0.1. The broader matrix was not fully rerun for wrapper 1.0.1.

Install

pnpm add @limelink/react-native

Android consumers add the public repository to android/settings.gradle:

dependencyResolutionManagement {
  repositories {
    google()
    mavenCentral()
    maven {
      url = uri("https://hellovelop.github.io/limelink-aos-sdk-binary/repository")
      content { includeGroup("org.limelink") }
    }
  }
}

For React Native templates that prefer project repositories, add the same Maven block under allprojects.repositories in android/build.gradle. The Expo plugin configures both locations idempotently.

The package resolves:

  • Android: org.limelink:limelink-aos-sdk:1.0.1
  • iOS: binary CocoaPod LimelinkIOSSDK 1.0.1

No GitHub credentials or native source overrides are required. Expo Development Build users add the packaged config plugin:

{
  "expo": {
    "plugins": ["@limelink/react-native"]
  }
}

The plugin configures the Android Maven repository and warm-link Activity intent update. Expo Go cannot load the native module.

Usage

import LimeLink from '@limelink/react-native';

const subscription = LimeLink.addLinkListener({
  onDeeplinkReceived(result) {
    console.log(result.deeplinkUrl, result.source, result.originalUrl);
  },
  onDeferredDeepLinkNotFound() {
    console.log('No deferred link');
  },
  onDeeplinkError(error) {
    console.error(error.code, error.message, error.platform);
  },
});

LimeLink.initialize({
  projectId: '550e8400-e29b-41d4-a716-446655440000',
  loggingEnabled: __DEV__,
});

const outcome = await LimeLink.handleDeferredDeepLink();
if (outcome.status === 'matched') console.log(outcome.result.deeplinkUrl);
if (outcome.status === 'failed') console.error(outcome.error);

subscription.remove();

Deferred deep links are supported automatically without an initialization flag. Manual deferred calls deliver through both the Promise and native listener. Choose one as the navigation owner.

Native SDK 1.0.1 uses one result contract for direct, Universal/App, and deferred links. An unresolved Universal/App Link is delivered as a successful callback with deeplinkUrl: null, the exact inbound URL in originalUrl, source: 'universalLink', and isDeferred: false; it does not emit a separate error callback.

On iOS, forward AppDelegate/SceneDelegate lifecycle callbacks directly to LimeLink.handleIncomingLink(_:) as shown in the package README; do not forward Linking.getInitialURL() or JavaScript URL events back into LimeLink. The native SDK owns cold buffering, deduplication, and success replay; errors and deferred notFound are live-only. Keep the application listener registered until it is no longer needed. Android owns cold and warm App Link lifecycle handling; do not recreate and forward the initial URL as a new Intent. MainActivity.onNewIntent must call setIntent(intent).

Configure Android App Links and iOS Associated Domains for the assigned LimeLink domain.

Development

pnpm install
pnpm build
pnpm typecheck
pnpm lint
pnpm test
pnpm docs:validate

Run examples:

pnpm community:android
pnpm community:ios
pnpm expo:android
pnpm expo:ios

Replace the sample Project ID and example.limelink.org before testing real links. See docs/README.md for the API contract, architecture, and test strategy.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages