0.0.10 • Published 1 year ago
@hongtangyun/client-web-sdk v0.0.10
@hongtangyun/client-web-sdk
Getting started
$ npm install @hongtangyun/client-web-sdk --save
Usage
import sdk from '@hongtangyun/client-web-sdk';
const token = 'xxxx';
async function init() {
sdk.config({
token: '',
});
sdk.launch(
document.querySelector('#root'),
{
onChange: (data) => {
console.log(data)
},
onError:(error) => {
console.log(error)
}
}
)
}
方法
方法 | 描述 |
---|---|
config | 初始化sdk配置 |
launch | 加载房间 |