0.0.10 • Published 2 years ago

@atomfinance/atom-web-sdk v0.0.10

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

atom-web-sdk

Our Atom Finance web SDK.

This SDK allows our B2B partners to interact with Atom content in their own application or website.

Install

With npm

$ npm i @atomfinance/atom-web-sdk

With yarn

$ yarn add @atomfinance/atom-web-sdk

How it works

This SDK exports one function (renderAtomContent) that creates an iFrame with Atom content sourced from platform.atom.finance. renderAtomContent takes in the following parameters:

  • partnerID: string: unique ID identifying the partner calling the function
  • token: string: unique user Id token identifying the user accessing the Atom content
  • iFrameElementID: string: id of the iframe element embedding the atom content
  • cbackFcn?: () => void: a partner supplied callback function that can be called from within the iframe. This can be used to trigger a custom event, such as redirecting to a new page.

Example

If you wanted to call this function, it would look something like this.

renderAtomContent(
  'atom-partner-123',
  'userToken123',
  'atom-content-parent',
  () => console.log('hello from within the iframe!')
)

Demo

Check out our demo here!

0.0.10

2 years ago

0.0.9

2 years ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago