question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Facebook] Sharing with Image

See original GitHub issue

I realize that not everyone wants to integrate with Facebook but given it’s one of the largest social media platforms, is it worthwhile considering a better intgration so that images can be shared when sharing on Facebook?

Steps to reproduce

Use a file:// url and notice how Share.open will not populate the Facebook post with an image. Share.shareSingle actually fails to open the webpage.

Expected behaviour

This may require an integration with Facebook, but if present, sharing on Facebook is quite easy like below.

import { ShareDialog } from 'react-native-fbsdk';

const photoUri = 'file://' + '/path/of/photo.png'
const sharePhotoContent = {
  contentType: 'photo',
  photos: [{ imageUrl: photoUri }],
}
ShareDialog.show(sharePhotoContent);

Environment

  • React Native version: 0.57.8
  • React Native platform + platform version: iOS 12

react-native-share

Version: 1.1.3

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
jgcmarinscommented, Jul 4, 2019

I guess that rn-fetch-blob works fine for both Android and iOS

1reaction
anshuul-kaicommented, Jan 23, 2019

Excellent!

I’d be happy to provide a PR given I have some specifications and a little help with reviewing.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Images in Link Shares - Meta for Developers - Facebook
Describes how to specify image(s) in link shares, how to ensure they are ... Pre-cache the image with the Sharing Debugger: Run the...
Read more >
Specify Link Title and Image - Sharing - Meta for Developers
How to Specify a Link Title and Image for a Shared Link ... Debugger to verify that your server is returning the correct...
Read more >
Share photos on Facebook | Facebook Help Center
1. At the top of your Feed, tap Photo. ; 2. Tap Camera to take a photo, or tap Browse to select photos...
Read more >
Share photos or videos from your Facebook Page
Share photos or videos from your Facebook Page ; 1. Tap in the top right of Facebook. ; 2. Tap Pages. ; 3....
Read more >
Share photos on Facebook | Facebook Help Center
Share photos on Facebook · At the top of your Feed, tap Photo. · Tap Camera to take a photo, or tap Browse...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found