npm.io
0.1.0 • Published 7 years ago

@neo-react/local-wallet

Licence
MIT
Version
0.1.0
Deps
6
Size
132 kB
Vulns
0
Weekly
0

@neo-react/local-wallet

React component that helps to handle encrypting and decrypting NEO wallet keys.

Demo

Click

Usage

import React from "react";
import LocalWallet from "@neo-react/local-wallet";

interface ConnectedWallet {
  provider: string;
  address: string;
  encryptedKey?: string;
  privateKey?: string;
}

const WalletModal = () => {
  return(
    <LocalWallet 
      onConnected={(connectedWallet: ConnectedWallet) => {
        /* Handle data using your own state manager */
      }} 
    />
  )
}

Api

Props Type Description
savedWallets array It passes encrypted key list.
onConnected func It returns wallet data after it is connected.

Keywords