0.4.0 • Published 3 years ago

credify-web-react v0.4.0

Weekly downloads
-
License
-
Repository
github
Last release
3 years ago

credify-web-react

This is a React package of Credify Web SDK.

How to use

$ npm install credify-web
$ npm install credify-web-react

First, you need to call defineCustomElements() in your application.

/// index.ts or index.js
import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import registerServiceWorker from './registerServiceWorker';

// Additional lines
import { applyPolyfills, defineCustomElements } from 'credify-web/loader';

ReactDOM.render(<App />, document.getElementById('root'));
registerServiceWorker();

// Additional lines
applyPolyfills().then(() => {
  defineCustomElements();
});

Then, you can import React components like following.

import { CredifyModal } from 'credify-web-react';

const sample = () => {
  return (
    <div>
      <CredifyModal></CredifyModal>
      ...
    </div>
  )
}

Note

When you distribute this SDK, you will need to remove the first line in components.d.ts.

0.4.0

3 years ago

0.3.0

3 years ago

0.3.1

3 years ago

0.2.0

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.0.8

3 years ago

0.1.4

3 years ago

0.1.3

3 years ago

0.0.7

3 years ago

0.1.0

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago