AMP Whatsapp Share Button for Blogger - Working Code

Mobility has become the predominant medium today that's enabling global digitization transformation. The worldwide mobile phone penetration rate is estimated increase quickly and by 2020 almost 5.4 billion people will own handsets.

In the past (2015) worldwide mobile data traffic added to 3.7 exabytes/month, but by 2020 it is expected to reach 30.6 exabytes/month globally.

People are sharing stuffs with each other easily and frenzily, with the help of Social networking share buttons. Fast rendering, mobile friendly Accelerated Mobile Pages (AMP) are all craze now.
Since WhatsApp has witnessed the rise in its popularity as the most popular communicator, it is important for Bloggers to tap the potential of WhatsApp to improve their mobile traffic. Let us implement AMP Whatsapp share button in this tutorial.

Step 1: The amp-social-share component will have to be added in the header.
<script async='async' src="https://cdn.ampproject.org/v0/amp-social-share-0.1.js" custom-element="amp-social-share" ></script>
Step 2: Add a Layout gadget element and introduce this code.
<b:if cond='data:blog.isMobileRequest == &quot;true&quot;'>
<amp-social-share data-share-endpoint="whatsapp://send" expr:data-param-text="&quot;Check out - &quot; + data:blog.canonicalUrl" layout="container" type="whatsapp">
<amp-img alt="Share via Whatsapp" height="45" layout="fixed" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhfuIcqTmzkAneRU4i-poRGwGBhvZGUBok3hGhhLe6d1EMXy2ll0u6G4t370WH7rDuq__7p2OGCLWYr-vUi1bxETfqtFpww6NLu0311hJ8CZWJk1eawUCK2saC9ln7dZN6BQVn2U6Uhyphenhyphen5n8/s1600/whatsapp-256.png" width="45">
</amp-img></amp-social-share>
</b:if>
Step 3: You'll get a whatsapp share button like this visible when the page is viewed through mobile -