Getting Started
Installation
Using a package manager
Use your favourite package manager to install:
- npm
- Yarn
- pnpm
npm install --save @agoralabs-sh/avm-web-provider
yarn add @agoralabs-sh/avm-web-provider
pnpm add @agoralabs-sh/avm-web-provider
Download via a CDN
Include the minified browser bundle directly in your HTML like so:
<html>
...
<script src="https://github.com/agoralabs-sh/avm-web-provider/releases/latest/download/avm-web-provider.min.js"></script>
...
</html>
Initialization
Firstly, we want to initialize the AVM web client:
- JavaScript (via package manager)
- JavaScript (via CDN)
- TypeScript
const { AVMWebClient } = require('@agoralabs-sh/avm-web-provider');
const client = AVMWebClient.init();
var client = window.AVMWebProviderSDK.AVMWebClient.init();
import { AVMWebClient } from '@agoralabs-sh/avm-web-provider';
const client: AVMWebClient = AVMWebClient.init();
note
See IAVMWebClientInitOptions
for more information on what options are supported.