Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@byteplus/live-sdk

Package Overview
Dependencies
Maintainers
21
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@byteplus/live-sdk

By integrating Viewer SDK, you can get a live broadcast experience with delay, higher quality, and smoother playback, including a variety of exciting interactive gameplay, such as voting, polling, lottery, interactive chat, product association and other d

  • 1.1.16
  • latest
  • publish-npm
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-66.67%
Maintainers
21
Weekly downloads
 
Created
Source

Viewer SDK

By integrating Viewer SDK, you can get a live broadcast experience with delay, higher quality, and smoother playback, including a variety of exciting interactive gameplay, such as voting, polling, lottery, interactive chat, product association and other displays.

Demo experience

You can use the SDK demo playground modify the template code and preview the effect in real time to achieve online effect debugging. See the Viewer SDK demo playground for details.

Installation

npm install @byteplus/live-sdk

Usage

Notice: Viewer SDK handles many compatibility issues for PC and mobile separately internally, so you need to ensure that you import the corresponding scripts and CSS files in the corresponding UA.

CDN

Reference https://docs.byteplus.com/en/byteplus-livesaas/docs/integrating-the-web-viewer-sdk

NPM

// PC:
import '@byteplus/live-sdk/dist/pc/js/index.js'
import '@byteplus/live-sdk/dist/pc/css/index.css'

// Mobile:
import '@byteplus/live-sdk/dist/mobile/js/index.js'
import '@byteplus/live-sdk/dist/mobile/css/index.css'

var webSDK = new window.ByteLiveWebSDK({
  activityId: *************,
  token: '****',
  service: '',
  mode: 1,
  modules: [
    {
      id: "player",
      mode: "player", 
    }, 
    {
      id: "menu", 
      mode: "menu",
      menu: ["comment"],
    }
  ],
  options: {}
})

webSDK.emit('player.pause'); // Trigger events
webSDK.on('player.pause', () => {}); // Listen for events 

FAQs

Package last updated on 08 Mar 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc