I tried to share article current URL to social media such as Facebook, Twitter & LinkedIn using react-share package. I have some issues at share the page: (URL: https://www.linkedin.com/shareArticle/?url=https%3A%2F%2Fstaging.bidboxid.co%2Fcar-details%2Fhonda-brio-at-limited-edition&mini=true)
code:
import React from 'react';
import { LinkedinShareButton } from "react-share";
let shareUrl = window.location.href;
export default class Share extends React.Component {
render() {
return(
<LinkedinShareButton url={`${shareUrl}`}>
<div className="icon-socmed-white linkedin">
<FaLinkedinIn/>
</div>
</LinkedinShareButton>)
}
}
What weird of this case, if I tried to share the homepage page as share article it'll works just fine.