LonelyCpp / react-native-youtube-iframe

A wrapper of the Youtube-iframe API built for react native.
https://lonelycpp.github.io/react-native-youtube-iframe/
MIT License
610 stars 155 forks source link

initialPlayerParams not working modestbranding #231

Closed code4muktesh closed 1 year ago

code4muktesh commented 2 years ago

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.

LonelyCpp commented 2 years ago

can you please actually fill in the above comment on what the problem is?

code4muktesh commented 2 years ago

npmPackages: expo: ^44.0.6 => 44.0.6 react: 17.0.1 => 17.0.1 react-dom: 17.0.1 => 17.0.1 react-native: 0.64.3 => 0.64.3 react-native-web: 0.17.1 => 0.17.1 Expo Workflow: bare

"react-native-webview": "11.15.0", "react-native-youtube-iframe": "^2.2.2",

LonelyCpp commented 2 years ago

What is not working?

Can you clarify what your expectation is and what you're getting?

code4muktesh commented 2 years ago

Setting modestbranding flag 1 but youtube logo is still visible in video toolbar....this flag is not working. youtube logo is always visible whether set 0 or 1.

IjzerenHein commented 2 years ago

The modestbranding param seems to be working just fine for me (both iOS and Android). I did notice that when you change it, you'll need to re-mount the videoplayer. Probably caused by the use of useMemo on this line: https://github.com/LonelyCpp/react-native-youtube-iframe/blob/f3d115e2c5d235dc9b4aee61c6ee74b177c23336/src/YoutubeIframe.js#L227

rvc2 commented 1 year ago

According to the YouTube development revision history, the modestbranding parameter has been deprecated and "will have no effect." Details here: YouTube modestbranding.

LonelyCpp commented 1 year ago

looks like modestbranding has been deprecated by youtube. this parameter has no effect since August 15, 2023

https://developers.google.com/youtube/player_parameters#modestbranding

I'll add a deprecated notice in a future release