WhatsApp url
Create a Whatsapp url
Install
$ yarn add whatsapp-url
Usage
const whatsappUrl = console// https://api.whatsapp.com/send?text=Hello%20World,%20its%20me%20Mario!&phone=5541984401163 console// https://web.whatsapp.com/send?text=Hello%20World,%20its%20me%20Luigi!&phone=5541984401163
When add the url
to a <a/>
tag it should work like this
Examples
Check the examples
API
whatsappUrl([options])
Returns a string
text
Type: string
Example: Hello%20World,%20its%20me%20Mario!
phone
Type: string
Example: 55984401163
Inspired by
bukinoshita/share-twitter - Thank you!
License
MIT © Fernando Moreira