Skip to content

Integrating Flutter Module in React Native with React Native Wrapper SDK

License

Notifications You must be signed in to change notification settings

KPS250/rn-login-sdk

Repository files navigation

rn-login-sdk

Flutter Module Wrapping for React Native

Installation

npm install rn-login-sdk

Integration in React Native

import React from 'react';
import { StyleSheet, View, Text, Pressable } from 'react-native';
import { openLoginSdk } from 'rn-login-sdk';

export default function App() {
  return (
    <View style={styles.container}>
      {/* Open Flutter Login SDK */}
      <Pressable style={styles.button} onPress={openLoginSdk}>
        <Text style={styles.text}>{'Open Login SDK'}</Text>
      </Pressable>
    </View>
  );
}

Integration for Android

Open android/build.gradle and add below snippet at the end:

allprojects{
    repositories{
        String storageUrl = "https://storage.googleapis.com"
        maven {
            url '../../../flutter_login_sdk/build/host/outputs/repo'
        }
        maven {
            url "$storageUrl/download.flutter.io"
        }
    }

Made with create-react-native-library

About

Integrating Flutter Module in React Native with React Native Wrapper SDK

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published