0

I think Facebook's oEmbed has multiple problems (as compared to other services like Twitter). Here's one of the test cases that I created and it seems to me that it fails:

Test case: https://rawgit.com/ile/deb38c4658c990cc67fcba06dbc4aed1/raw/550b757c38db4130b31f93c106f0fddc65cd9b21/oembed%2520test.html

How to test:

  • Click set 1, you should see a tweet
  • Click set 2, you should see a Facebook post (correctly embedded)
  • Click set 1, you should see a tweet
  • Click set 2, you should see only the "blockquote" code for Facebook. It's not updating to the embedded post.

So, when setting the oembed code into the DIV the second time, it doesn't work (it will not get expanded into an embedded post).

Any feedback on this? Does the Facebook's oembed have a problem or is this test case not correctly done?

ile
  • 1,765
  • 1
  • 16
  • 19
  • Ok, this was marked as a duplicate. But I wanted to know if this is a bug in FB's oEmbed implementation. I think it is. The other question didn't answer that. ( @cbroe ) – ile Jul 06 '16 at 07:56
  • I would not consider it a bug - the basic embed code they return works. If you throw additional stuff into the mix (like the kind of “tabs” in your example, where you dynamically switch out document content via script), then it might need some extra handling, yes. But the FB JS SDK has always worked this way - for performance reasons. If the others, like twitter, do it a different way, then that’s up to them I think. – CBroe Jul 06 '16 at 08:34
  • The usecase is a "normal" social media app with a "link preview" feature, so there will be a lot of embedded posts. People add a post and a link preview pops up. But in this case it doesn't pop up since the social media app doesn't know it should be calling something (and it shouldn't know this). It's just the oEmbed code that should work "out of the box". – ile Jul 06 '16 at 08:46
  • Well then file a bug report with Facebook, if you think tis should be changed. – CBroe Jul 06 '16 at 09:19
  • I already did but they didn't seem to be very keen to accept it's a bug :) So I made these posts to clarify the issue. And I think it may have helped, not sure. https://developers.facebook.com/bugs/1612380195741803 – ile Jul 06 '16 at 09:23

0 Answers0