YT script does not load when run from a chrome extension
Current Behavior
I'm trying to render a ReactPlayer from a chrome extension, on a facebook page. Soundcloud players load fine, but not youtube's
Expected Behavior
The youtube iframe should be rendered, or an error should be raised.
Steps to Reproduce
- download the chrome repo (make sure you're on the
preactbranch) - load it as an unpacked extension
- open a facebook page containing a post with a youtube link
Environment
- URL attempting to play: any (but can try with this: https://www.youtube.com/watch?v=Rc2zdjQU7RA to reproduce)
- Browser: Brave/Chrome
Version 1.21.73 Chromium: 89.0.4389.72 (Official Build) (x86_64) - Operating system: MacOS 11.1
Other Information
From my debugging, it seems like this is never called. I'm unable to understand where exactly this fails. The extension modifies facebook headers to allow loading a script from https://youtube.com. It works fine with soundcloud
Running the code returned by youtube does add YT to the window, but it doesn't seem to indeed add it via load-script.
PS: embedding a regular youtube iframe works as expected(but you don't get the controls)
I also have the same problem, please help if there is a solution. Message show : Videos un available View on youtube