Package Gives Wrapper Methods for Deepwall Sdks

Package Gives Wrapper Methods for Deepwall Sdks

DeepWall (deepwall-react-native-sdk) .Package gives wrapper methods for deepwall sdks

DeepWall (deepwall-react-native-sdk)

  • This package gives wrapper methods for deepwall sdks. iOS - Android

  • Before implementing this package, you need to have api_key and list of actions.

  • You can get api_key and actions from DeepWall Dashboard

Getting started

$ npm install deepwall-react-native-sdk --save

React Native 0.59 and below

Run react-native link deepwall-react-native-sdk to link the library.

Installation Notes

  • IOS

    • Set minimum ios version to 10.0 in ios/Podfile like: platform :ios, '10.0'
    • Add use_frameworks! into ios/Podfile if not exists.
    • Remove flipper from ios/Podfile if exists.
    • Run $ cd ios && pod install
  • ANDROID

    • Set minSdkVersion to 21 in android/build.gradle
    • Add maven { url 'https://raw.githubusercontent.com/Teknasyon-Teknoloji/deepwall-android-sdk/master/' } into android/build.gradle (Add into repositories under allprojects)

Usage

Let's start

  • On application start you need to initialize sdk with api key and environment.
import DeepWall, { DeepWallEnvironments } from 'deepwall-react-native-sdk';

DeepWall.getInstance().initialize('API_KEY', DeepWallEnvironments.PRODUCTION);
  • Before requesting any landing page you need to set UserProperties (device uuid, country, language). See all parameters
import DeepWall, { DeepWallUserProperties } from 'deepwall-react-native-sdk';

DeepWall.getInstance().setUserProperties(
  new DeepWallUserProperties({
    uuid: 'UNIQUE_DEVICE_ID_HERE (UUID)',
    country: 'us',
    language: 'en-us',
  }),
);
  • After setting userProperties, you are ready for requesting a landing page with an action name. You can find the action name in the DeepWall dashboard.
DeepWall.getInstance().requestLanding('AppLaunch');
  • You can also close landing.
DeepWall.getInstance().closeLanding();
  • If any of userProperties is changed you need to call updateUserProperties method. (For example if user changed application language)
DeepWall.getInstance().updateUserProperties({
  language: 'fr-fr',
});
  • There is also bunch of events triggering before and after DeepWall Actions. You may listen any action like below.
import DeepWall, { DeepWallEventBus, DeepWallEvents } from 'deepwall-react-native-sdk';

DeepWallEventBus.getInstance().listen(DeepWallEvents.LANDING_OPENED, function (data) {
  console.log(
    'DeepWallEvents.LANDING_OPENED',
    data
  );
});
  • For example you may listen all events from sdk like below.
import { DeepWallEventBus, DeepWallEvents } from 'deepwall-react-native-sdk';

Object.values(DeepWallEvents).map((item) => {
  DeepWallEventBus.getInstance().listen(item, function (data) {
    console.log(item, data);
  });
});

Notes

  • You may found complete list of events in Enums/Events.js or Native Sdk Page
  • UserProperties are:
    • uuid
    • country
    • language
    • environmentStyle
    • debugAdvertiseAttributions

Troubleshooting

Android

  • If you get NATIVE_MODULE_NOT_FOUND error, that means you have to link this library manually.
    • Add new instance of Deepwall package into src/main/java/com/YOUR-APP-NAME/MainApplication.java
// MainApplication.java

...
import com.deepwall.RNDeepWallPackage;// <-- Add this line.
...

protected List<ReactPackage> getPackages() {
  List<ReactPackage> packages = new PackageList(this).getPackages();
  packages.add(new RNDeepWallPackage()); // <-- Add this line.
  return packages;
}

Download Details:

Author: Teknasyon-Teknoloji

Source Code: https://github.com/Teknasyon-Teknoloji/deepwall-react-native-sdk

react-native react mobile-apps

Bootstrap 5 Complete Course with Examples

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

Building a simple Applications with Vue 3

Deno Crash Course: Explore Deno and Create a full REST API with Deno

How to Build a Real-time Chat App with Deno and WebSockets

Convert HTML to Markdown Online

HTML entity encoder decoder Online

How native is React Native? | React Native vs Native App Development

Article covers: How native is react native?, React Native vs (Ionic, Cordova), Similarities and difference between React Native and Native App Development.

React Native Mobile App Development

Skenix is providing React Native Development Services with qualified React Native App Developers. Get the best React Native App Development Services.

How React Native Is Shaping Mobile App Development

Are you a mobile app developer looking for more efficient tools for your projects? Mobile app development is getting tougher and tougher as the market continues to grow. As a developer, you need to develop Apps which meet the demands of your users. To achieve this, adopt the right tools, like the React Native development framework.

Top React Native Mobile App Development Companies in USA

Looking for top React Native mobile app development company in USA for Startups & Enterprise? Find out the top list of React Native mobile app development company in USA.

Which is the best React Native app development company in New York?

Hire top react native app development company in New York to build and develop custom react native mobile apps for Android & iOS with the latest features.