Latest Threat ResearchGlassWorm Loader Hits Open VSX via Developer Account Compromise.Details
Socket
Book a DemoInstallSign in
Socket

react-native-elastos-unity-wallet

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-elastos-unity-wallet

## Getting started

Source
npmnpm
Version
1.0.5
Version published
Weekly downloads
6
500%
Maintainers
1
Weekly downloads
 
Created
Source

React Native Elastos Wallet Plugin

The Elastos Unity wallet repository provides all the necessary code to port the wallet functionnalities to React Native. Developers can use the Elastos Unity wallet module to implement the Elastos wallet functionalities into their app. Elastos Wallet is used to manage private and public keys and to make transactions on the Elastos network, including DID sidechain.

Getting started

Due to the size limitation of npmjs.org, the Elastos Unity wallet module is actually available via git install from the npm command: $ npm install github:cyber-republic/elastos-unity-wallet --save

Mostly automatic installation

$ react-native link elastos-unity-wallet

Then, for only Android, it needs to follow the following Manual Installation Android Step 4.

Manual installation

iOS

  • In XCode, in the project navigator, right click LibrariesAdd Files to [your project's name]
  • Go to node_modulesreact-native-elastos-wallet-core and add RNElastosMainchain.xcodeproj
  • In XCode, in the project navigator, select your project. Add libRNElastosMainchain.a to your project's Build PhasesLink Binary With Libraries
  • Run your project (Cmd+R)

Android

  • Open up android/app/src/main/java/[...]/MainApplication.java
  • Add import org.elastos.mainchain.reactnative.RNElastosMainchainPackage; to the imports at the top of the file
  • Add new RNElastosMainchainPackage() to the list returned by the getPackages() method
  • Append the following lines to android/settings.gradle:
    include ':react-native-elastos-wallet-core'
    project(':react-native-elastos-wallet-core').projectDir = new File(rootProject.projectDir, 	'../node_modules/react-native-elastos-wallet-core/android')
    
  • Insert the following lines inside the dependencies block in android/app/build.gradle:
    implementation project(':react-native-elastos-wallet-core')
    
  • Insert the following lines inside the android block in android/app/build.gradle:
    packagingOptions {
        pickFirst '**/libc++_shared.so'
    }
    

Usage

import RNElastosMainchain from 'react-native-elastos-wallet-core';

// Generate a new mnemonic (defaults to English)
RNElastosMainchain.generateMnemonic((err, mnemonic) => {
    console.log(mnemonic)
});

The complete documentation is available on:

Keywords

elastos

FAQs

Package last updated on 29 Feb 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts