Skip to content

See bundle size and imports for lightweight core/composable entries, fixed skins, and individual controls. Existing aggregate imports remain supported.

API overview ​

Use the entries below as the public package interface. All components register their required upstream custom elements automatically.

Package entries ​

ImportRuntime exportsReference
videojs-vueVideoPlayer, PlayerRoot, Video, DefaultVideoSkin, NeutralVideoSkin, usePlayerState, usePlayerActionsPlayer, composition, media, composables
videojs-vue/audioAudioPlayer, AudioPlayerRoot, Audio, DefaultAudioSkin, NeutralAudioSkin, useAudioPlayerState, useAudioPlayerActionsAudio players
videojs-vue/media/hlsHlsVideoMedia adapters
videojs-vue/uiLayout, buttons, sliders, poster, hotkeys, and status announcerUI controls
videojs-vue/i18nMediaI18n, MediaText, and translation registry functionsInternationalization
videojs-vue/video/legacyVideoPlayer fixed to the legacy skinChrome 90+ legacy mode
videojs-vue/skins/legacyLegacyVideoSkin for compositionLegacy skin
videojs-vue/skins/legacy.cssStandalone legacy stylesheetLegacy styling
videojs-vue/polyfillsSide-effect-only global Array.prototype.at and Object.hasOwn polyfillsStartup order

The base entry does not import hls.js. Install @videojs/hlsjs-video@10.0.1 before importing the HLS entry.

core-js is an optional peer dependency used only by videojs-vue/polyfills. Install it with pnpm add core-js@^3.50.0 before importing that entry. Other entries do not require it; see legacy mode for when to load the polyfills.

Components ​

Use VideoPlayer for a complete player. Use PlayerRoot and skins with a media adapter when composing a player. Each root must contain exactly one media component.

Events ​

Player events documents ready, two-way setting updates, and the complete list of forwarded media events. UI controls pass listeners to their underlying custom elements.

State and actions ​

Composables and handles documents selectors, action return types, player targets, and exposed refs. For a complete application example, see the state and actions guide.

UI entry ​

UI controls lists every exported control and the properties supported by its Vue binding. See composition for layout and styling.

i18n entry ​

Internationalization API covers provider and text props, slots, and registry exports. See the internationalization guide for locale setup.

Type exports ​

EntryExported types
videojs-vueVideoMediaComponent, MediaEventName, MediaProps, MediaTrack, PlayerActions, PlayerHandle, PlayerElement, PlayerMedia, PlayerState, PlayerStore, PlayerTarget
videojs-vue/media/hlsHlsSource, HlsEngineConfig
videojs-vue/i18nTranslations, FlatTranslations, Locale

PlayerStore and PlayerState follow the upstream Video.js video preset. PlayerMedia describes the common native and adapter media surface; narrow the element type before using adapter-specific APIs.

Audio types are exported separately from videojs-vue/audio; see audio types and handles.