vidstack / player

UI components and hooks for building video/audio players on the web. Robust, customizable, and accessible. Modern alternative to JW Player and Video.js.
https://vidstack.io
MIT License
1.89k stars 114 forks source link

Player crashes in production build #1289

Closed booprodusan closed 1 week ago

booprodusan commented 1 month ago

Current Behavior:

Whenever I try building for production with npm run build I experience this error: Uncaught TypeError: Cannot read properties of undefined (reading 'media') at vidstack-BErtLkZy.js:295:54725

Error in vidstack-BErtLkZy.js:295:54725 appears in line: const dn = chrome.cast.media.TrackType.TEXT

Expected Behavior:

However, when I build for development with npm run dev, everything works as expected.

Environment:

mihar-22 commented 4 weeks ago

You'll need to provide a repro to help me figure out what's going on here. What bundler are you using?