Supports for Apple AirPlay API.
Name | airplay |
Global name¹ | window.VlitejsAirPlay |
Path | vlitejs/dist/plugins/airplay |
Entry point | vlitejs/dist/plugins/airplay/airplay.js |
Stylesheet | vlitejs/dist/plugins/airplay/airplay.css |
Provider² | 'html5' |
Media type³ | 'video' |
- ¹ Useful only if
vLitejs
is included with a<script>
tag (see CDN section).
<video id="player" class="vlite-js" src="<path_to_video_mp4>"></video>
import 'vlitejs/dist/vlite.css';
import 'vlitejs/dist/plugins/airplay.css';
import Vlitejs from 'vlitejs';
import VlitejsAirPlay from 'vlitejs/dist/plugins/airplay';
Vlitejs.registerPlugin('airplay', VlitejsAirPlay);
new Vlitejs('#player', {
plugins: ['airplay']
});
The plugin exposes the following native Event
on the .v-vlite
element.
Event Type | Description |
---|---|
airplaysessionstarted |
Sent when the AirPlay session is established. |
airplaysessionended |
Sent when the AirPlay session is disconnected. |
The subtitle plugin does not display subtitles on the AirPlay screen.