Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Youtube link not working #45

Open
aneena-thomas opened this issue Jun 24, 2021 · 6 comments
Open

Youtube link not working #45

aneena-thomas opened this issue Jun 24, 2021 · 6 comments

Comments

@aneena-thomas
Copy link

aneena-thomas commented Jun 24, 2021

Youtube link not working, just showing youtube icon
@maherzaidoune

@maherzaidoune
Copy link
Owner

Hi, Sorry I was quite busy and didn't look into the package for a while, I'll take a look at that in the next few days.

@Amazing1974
Copy link

any update?

@ahaverty
Copy link

We're seeing this on iOS, but android is still working as expected

@ahaverty
Copy link

The same link,
iOS:
image
vs Android:
image

@Joshmatjjen
Copy link

@maherzaidoune Adding a user agent to the reques header might solve this

headers: {
'User-Agent':
'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36'
}

@sujatha2016
Copy link

sujatha2016 commented Mar 1, 2022

Thanks to Josh

added as getLinkPreview(text, { imagesPropertyType: 'og', // fetches only open-graph images headers: { 'User-Agent': 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36', }, timeout: 1000, }) in

_node_modules/react-native-url-preview/index.js_

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants