react-youtube icon indicating copy to clipboard operation
react-youtube copied to clipboard

How To Hide Related Videos?

Open cyruslk opened this issue 3 years ago • 4 comments

Is there a way to add related videos that appear on pause?

Thanks a lot in advance and immense gratitude for this package.

cyruslk avatar May 18 '21 02:05 cyruslk

I don't believe this is possible: https://developers.google.com/youtube/player_parameters#rel

you will not be able to disable related videos. Instead, if the rel parameter is set to 0, related videos will come from the same channel as the video that was just played.

michaeltnguyen avatar Aug 06 '21 01:08 michaeltnguyen

As @michaeltnguyen said, you cannot disable them. They used to be disable-able in the past but Google changed that. Now you can only limit the related videos to the same channel of the video playing (rel=0)

Abdelalim-dev avatar Apr 05 '22 07:04 Abdelalim-dev

YouTube's default UI elements can be hidden, related videos can be hidden, and ads can be removed from YouTube videos in react native.

It may help you to meet your requirements if you use the below-mentioned package: https://www.npmjs.com/package/react_native_youtube_streamer

Besides being open source, the package is scalable as well. It is also possible for you to contribute to that project.

staticGuru avatar Oct 30 '22 09:10 staticGuru

opts={{ playerVars: { controls: 0, rel: 0 } }}

PetersonFonseca avatar Jan 14 '23 09:01 PetersonFonseca