Skip to main content
Back to plugins
@capgo/capacitor-mux-player
Tutorial
@capgo/capacitor-mux-player

Mux Player

Stream adaptive bitrate video with Mux player for optimized playback quality

Guide

Tutorial on Mux Player

Using @capgo/capacitor-mux-player

Native Mux Player SDK to play video on IOS and Android.

Install

bun add @capgo/capacitor-mux-player
bunx cap sync

What This Plugin Exposes

  • play - Launch the native Mux Player in fullscreen and begin playback.
  • dismiss - Dismiss the player if it is visible.
  • isActive - Returns whether the player is currently being displayed.

Example Usage

play

Launch the native Mux Player in fullscreen and begin playback.

import { MuxPlayer } from '@capgo/capacitor-mux-player';

await MuxPlayer.play({} as MuxPlayOptions);

dismiss

Dismiss the player if it is visible.

import { MuxPlayer } from '@capgo/capacitor-mux-player';

await MuxPlayer.dismiss();

isActive

Returns whether the player is currently being displayed.

import { MuxPlayer } from '@capgo/capacitor-mux-player';

await MuxPlayer.isActive();

Full Reference

Keep going from Using @capgo/capacitor-mux-player

If you are using Using @capgo/capacitor-mux-player to plan native media and interface behavior, connect it with @capgo/capacitor-mux-player for the implementation detail in @capgo/capacitor-mux-player, Getting Started for the implementation detail in Getting Started, Using @capgo/capacitor-live-activities for the native capability in Using @capgo/capacitor-live-activities, @capgo/capacitor-live-activities for the implementation detail in @capgo/capacitor-live-activities, and Using @capgo/capacitor-video-player for the native capability in Using @capgo/capacitor-video-player.