Skip to content

quan-to/connect-web-embedded

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Connect Web Embedded

FOSSA Status

This web client will help you as a partner to initialize Quanto Connect embedded in your application.

Demo

https://connect-4k39dld76.vercel.app

Installing

Using npm:

$ npm i @quan-to/connect-web-embedded

Using yarn:

$ yarn add @quan-to/connect-web-embedded

Using cdn:

<script src="https://cdn.jsdelivr.net/npm/@quan-to/connect-web-embedded@1.1.8/dist/index.min.js"></script>

Creating an instance

How you can create a new instance of Connect.

new Connect([config])

const connect = new Connect({
  // Connect Session ID
  session: 'c889f8e9-8c58-456d-8f35-3840a292a574',

  // Connect Session environment
  env: 'sandbox',
});

How to use

import { Connect } from '@quan-to/connect-web-embedded';

const connect = new Connect({
  session: 'c889f8e9-8c58-456d-8f35-3840a292a574',
  env: 'sandbox',
});

connect.onLoad(() => {
  console.log('Do something');
});

connect.onSuccess(() => {
  console.log('Do something');
});

NOTE: the Connect module is defined in the global scope for usage with CDN, without strict mode or a module loader (ESM or CJS).

Callbacks

method params return description
onLoad function void This callback will be call when Connect is ready
onExit function void This callback will be call when the user leaves the application
onAuthSuccess function data This callback will be call after user login
onAuthFail function void This callback will be call after user login fail
onSelectBank function data This callback will be call after user select a bank
onAddAccountSuccess function data This callback will be call after user add a new account
onGrantedPermission function data This callback will be call when user granted the permission and return the permission
onSuccess function void This callback will be call when user finished the flow with success

Run and Build

Run(watch):

$ yarn start

Build:

$ yarn build

About

Stack

Contributing

Link

Support

suporte@quan.to

License

FOSSA Status

About

Javascript Web Embedded to start Connect on Partner's application

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published