Questions tagged [react-player]

react-player is a React component for playing a variety of URLs, including file paths, YouTube, Facebook, Twitch, SoundCloud, Streamable, Vimeo, Wistia, Mixcloud, DailyMotion and Kaltura. More information can be found at https://github.com/CookPete/react-player.

213 questions
0
votes
0 answers

How to load video from local file URL without MediaStream

What's the way play local videos? This option doesn't work: const url = '/localVideo.mp4'; I get the error that src attribute is empty: MediaError…
Max Koretskyi
  • 101,079
  • 60
  • 333
  • 488
0
votes
0 answers

React-Player video text track is working for kind "subtitles" but not for kind "chapters"

I have integrated React-player https://www.npmjs.com/package/react-player and want to track the video. I have configured it as
0
votes
0 answers

Unable to display vimeo video fullscreen using react-player on mobile phones (see attached image for best I can manage)

Using react-player, I want a full screen video on mobile. I've tried using 'playinline' on and off, 'background', 'responsive', 'padding-top' 57% etc, but I always end up with gaps at the top and/or bottom (as you can see in the image above - the…
cordial
  • 87
  • 8
0
votes
0 answers

How to pause using React Player without using controler prop

my playSvg is working properly but I would like to add when you click on the second time the play button svg appears again, can someone help me please!
giegie
  • 3
  • 2
0
votes
0 answers

how to avoid double network requests

My goal is to set a start time for video. Currently, my component looks like this: const VideoPlayer = () => { const [config] = useState({ url:…
Jackie
  • 39
  • 5
0
votes
0 answers

React player - how to avoid double network requests when I am setting the start time of file

As I mentioned in the title I am using react-player. My goal is to set start time for video. Currently my component looks like this: const VideoPlayer = () => { const [config] = useState({ url:…
huhWell
  • 89
  • 1
  • 2
  • 6
0
votes
0 answers

React-player - How to set start time for mp4 videos

I would like to set start time for my mp4 video. I know I can use something like that when I am using youtube video, but I have no idea if there is a way to this with classic mp4 video
huhWell
  • 89
  • 1
  • 2
  • 6
0
votes
1 answer

React not playing videos on safari

I am trying to play a self hosted video on safari , i looked many solutions online i tried playsinline, i set the headers type. I tried multiple encodings for videos and formats noone of it managed to work , the snippet for the player is like…
0
votes
2 answers

How to React Player fit in div box?

How to React Player fit in div box? My code is like this but the React Video doesn't fit box like photo XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX Top.js {camera.map((item,i) => …
user15346124
0
votes
0 answers

Enable closed captions using React Player

I am struggling to show closed captions using React Player whilst playing an HLS stream, I looked everywhere and I only see how to add subtitles from files. The stream already has closed captions embedded, I need to show them. In the browser, I can…
yesigye
  • 66
  • 5
0
votes
2 answers

ReactPlayer can not play video when given a locahost url address

ReactPlayer.js cannot play the video streamed from an API. Please need some here
isaac
  • 19
  • 5
0
votes
1 answer

Video pause on scroll (React.js | material UI)

I have a video on my site that I want to be paused when I scroll it and play only when its visible. I have tried some solutions from internet but things are not working out. This is my current code. I have tried out a solution from stackoverflow…
Manas S. Roy
  • 303
  • 1
  • 10
0
votes
2 answers

Pause other videos when slide is changed | Swiper.js | React Player

I need help for my video carousel using Swiper.js and React Player. I want to stop the video when swiped and became inactive slide. I set the state like below and it does behave as I wanted. But now, it autoplays the active slide even autoplay prop…
Chi
  • 276
  • 1
  • 8
  • 20
0
votes
1 answer

How to enable picture-in-picture mode in ReactPlayer?

I'm new to reactjs. Here, I'm trying to add a picture-in-picture mode in ReactPlayer. I have searched and I found the npm install react-use-pip package, I run the below sample code of this package separately, and it's working fine. But, when I…
0
votes
0 answers

React Player plays video when a user is on the video section and pauses when not

I want to achieve the feature when a user is in the video section React player will play the video and pause when the user leaves the section.