Initializing the widget
Getting started with Venly Connect, our JavaScript Widget for easy integration.

Step 1: Including the widget

Venly Connect has been published to npmjs.com. So by using npm, you can fetch it by executing the following:
1
npm i @venly/connect
Copied!
You can also download it directly via UNPKG CDN.
πŸ§™ It is best to point Venly Connect to a specific version when including its URL in your code. See https://unpkg.com/ for more info.

Step 2: Initializing the widget, with Venly Connect

Create a VenlyConnect instance with your Client ID with the following script. Your Venly Client ID is required when calling this function, as it identifies your app to Venly.
1
const venlyConnect = new VenlyConnect('Testaccount');
Copied!
πŸ§™ To connect with a personalised Client ID, and access our production environment, please request access one using this form.
The VenlyConnect object is your entry point to the rest of the widget functionalities, below is its signature. You can connect to several networks and environments by using the ConstructorOption 'Environment'.
1
//Signature VenlyConnect
2
VenlyConnect(clientID:string, options?: ConstructorOptions)
Copied!

Congratulations, your app is now blockchain-enabled! πŸŽ‰

After putting the 2 code snippets above into the editor, your app is now blockchain-enabled!
Last modified 1d ago