open-index/open-npm huggingface dataset:
npm package: @portmone-ai/sdk-react
Description: Portmone React SDK is dedicated to help the Partner to properly render the QR code that represents the data share request from Portmone.
Author: Maksym Khudiakov
Latest version: 0.1.2

## Portmone React SDK
Portmone React SDK is dedicated to help the Partner to properly render the QR code that represents the data share request from Portmone.

## How to install
```shell script
npm i @portmone-ai/sdk-react
```

## How to use
The usage is super simple. But as the first step the Data Share Request must be generated by the Partner.

That is achieved on the server side and consists of 2 steps:

1. Partner authentication
2. Data Share Request generation

Once the data share request is generated, it is provided to the SDK:
```shell script
import React from 'react';
import PortmoneQRCode from '@portmone-ai/sdk-react'


class SignInPage extends React.Component {

  constructor(props) {
    super(props)
  }

  onSuccess = (id) => {
    /* TODO: Data Share Request approved by the Customer User, thus redirect ... */
  }

  render() {
    return (
      <PortmoneQRCode code={this.props.code} onSuccess={this.onSuccess} />
    );
  }
}

export default SignInPage
```