Share base64 with expo-sharing

I have a base64 code that is a QR code and I want to share it on social networks with
expo-sharing.
But i can’t find a way to do it, i know it only accepts url, so try using expo FileSystem to download a cached file and get url, but the error remains the same, I don’t know how to use the downloadAsync method with base64 code, does anyone have any idea how to do it?

I have the same problem. base64 I get from qrCode. I need to send qrCode image through sharing on social networks If you have already found a solution, please write

I have the same issue. I have a base64 code which is a QRcode i want to share on social networks.

I don’t know if it’s the best way to do it but it worked for me.

//any picture

import * as FileSystem from 'expo-file-system';
import * as Sharing from 'expo-sharing';



  share=(base64)=>{
    var self = this;
   //any picture
    const image_source = 'https://images.unsplash.com/photo-1508138221679-760a23a2285b?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&w=1000&q=80';

          FileSystem.downloadAsync(
          image_source,
          FileSystem.documentDirectory  + '.png'
        )
          .then(({ uri }) => {
            FileSystem.writeAsStringAsync(
                uri,
                base64,
                {'encoding':FileSystem.EncodingType.Base64}
            )
            .then(( ) => {
              Sharing.shareAsync(uri);
            })

          })
          .catch(error => {
            console.error(error);
          });
  }