Support a link within InnerText [duplicate]

I’m trying to get the message that’s being rendered by this function to have the link part clickable. (highlighted it with asterisks)
Right now it’s just acting like a string.
I’ve tried adding anchor tags but to no avail.

  function onSuccess(uploadedImgUrl) {
    const encodedUploadedImgUrl = encodeURIComponent(uploadedImgUrl);
    document.querySelector(
      '.user-msg'
    )**.innerText = `Your photo is available here:
     ${uploadedImgUrl}`;**

    document.querySelector('.share-container').innerText = `
        <a class="btn" href="https://www.facebook.com/sharer/sharer.php?u=${encodedUploadedImgUrl}&t=${encodedUploadedImgUrl}" title="Share on Facebook" target="_blank" onclick="window.open('https://www.facebook.com/sharer/sharer.php?u=${uploadedImgUrl}&t=${uploadedImgUrl}'); return false;">
           Share   
        </a>`;
  }
  doUploadImg(imgDataUrl, onSuccess);
}

Would appreciate any kind of help!