-
-
Notifications
You must be signed in to change notification settings - Fork 10.1k
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
Editor: Resolve more oembed URLs (e.g. Facebook posts) #9786
Comments
@kirrg001 I will take a look into it. |
@lunaticmonk the opengraph work is already planned. What could be useful is a PR to https://github.com/iamcal/oembed that adds a |
@kevinansfield Gotcha! I will take a look into it and do the needful. Seems the https://github.com/iamcal/oembed has |
@kevinansfield What all providers do we need? I am making PR for the |
@lunaticmonk Facebook only has post and video oembed endpoints, there's no separate one for photos - https://developers.facebook.com/docs/plugins/oembed-endpoints/ |
@kevinansfield Created a pull request here: iamcal/oembed#305 |
Thanks @lunaticmonk 👍 I've added a comment over on the PR, let's keep discussion there for now 😄 |
refs #9786 - bumped `oembed-parser` dependency to a forked version - contains fix for oembed.com providers that include `{format}` in the `url` - contains updated `providers.json` file including the `Facebook (Post)` provider (thanks @lunaticmonk)
@kevinansfield @kirrg001 Can we close this issue if this is resolved? |
@lunaticmonk the second part of this issue is still open - we’d like to look for the oembed meta tag if there’s no known provider. This would have avoided the need to manually edit the providers list |
@kevinansfield I understand. Currently, the providers that are added to the providers return a html in the response from the oembed endpoint. Consider a case when no provider is found, do we want to have our own custom card for it and fetch the meta tags from the input url? |
@lunaticmonk that’s a different issue :) we already have designs for that. This issue is about loading oembed data for providers that we don’t have explicit oembed endpoints for |
closes #9786 - Make GET request when url has no provider match - The HEAD request was made in order to send less data over the wire when checking for redirects for urls that do not have an oembed provider match. We are now going to look for provider metatags withing the response of the request - rather than making a HEAD followed by a GET if no redirect is found, this condenses that to a single request. - Try to get OEmbed data from tag if no provider - Here we parse the HTML response of the resource and look for a link tag that will give us the oembed resource url which we can use to fetch the embed html
There are some embed links which are not supported yet e.g. Facebook posts.
Note: Facebook post embeds were enabled in #9803, we still want to enable the
<link rel="alternate">
lookup mentioned below to support other providers that may not be listed on https://oembed.comSteps to reproduce
Plan
There's a two prong approach to this issue:
<link rel="alternate" type="application/json+oembed" href="...">
tag when no local lookup is possibleThe text was updated successfully, but these errors were encountered: