<commit_before># WhatsApp sharing button

[![Tips](https://img.shields.io/gratipay/kriskbx.svg)](https://www.gittip.com/kriskbx/) [![Travis](https://img.shields.io/travis/kriskbx/whatsapp-sharing.svg)](https://travis-ci.org/kriskbx/whatsapp-sharing) [![Code Climate](https://img.shields.io/codeclimate/github/kriskbx/whatsapp-sharing.svg)](https://codeclimate.com/github/kriskbx/whatsapp-sharing) [![Release](https://img.shields.io/github/release/kriskbx/whatsapp-sharing.svg)](https://github.com/kriskbx/whatsapp-sharing) [![GitHub license](https://img.shields.io/github/license/kriskbx/whatsapp-sharing.svg)](https://github.com/kriskbx/whatsapp-sharing/blob/master/LICENSE) [![Npm](https://img.shields.io/npm/dm/whatsapp-sharing.svg)](https://www.npmjs.com/package/whatsapp-sharing)


## Installation

### 1. Download

* With Npm: `npm install whatsapp-sharing`
* With Bower: `bower install whatsapp-sharing`
* With Git: `git clone https://github.com/kriskbx/whatsapp-sharing.git`
* Manually: [https://github.com/kriskbx/whatsapp-sharing/releases](https://github.com/kriskbx/whatsapp-sharing/releases) 

Or include the hosted version on [jsdelivr](http://www.jsdelivr.com/): `//cdn.jsdelivr.net/whatsapp-sharing/1.3.2/whatsapp-button.js`

### 2. Integrate the buttons source

Use this code right before the `</body>`, replace `http://your-domain.tld/path/whatsapp-button.js` with the url to the just uploaded file.

	<script type="text/javascript">	if(typeof wabtn4fg==="undefined")	{wabtn4fg=1;h=document.head||document.getElementsByTagName("head")[0],s=document.createElement("script");s.type="text/javascript";s.src="http://your-domain.tld/path/whatsapp-button.js";h.appendChild(s)}</script>

### 3. Place it on your website

Place this code somewhere on your website to display the button:

	<a href="whatsapp://send" data-text="Take a look at this awesome website:" data-href="" class="wa_btn wa_btn_s" style="display:none">Share</a>
	
If you want to customize the size, style, url or the sharing text, feel free to visit [whatsapp-sharing.com](http://www.whatsapp-sharing.com) for a code generator.

## FAQ

### 1. I'm using AJAX?

Run `WASHAREBTN.crBtn();` after you loaded your content.

### 2. I want to track clicks on the button.

You can simply use JavaScript event handlers like `onClick` in the code of step 3.
<commit_msg>changed jsdevlir version<commit_after># WhatsApp sharing button

[![Tips](https://img.shields.io/gratipay/kriskbx.svg)](https://www.gittip.com/kriskbx/) [![Travis](https://img.shields.io/travis/kriskbx/whatsapp-sharing.svg)](https://travis-ci.org/kriskbx/whatsapp-sharing) [![Code Climate](https://img.shields.io/codeclimate/github/kriskbx/whatsapp-sharing.svg)](https://codeclimate.com/github/kriskbx/whatsapp-sharing) [![Release](https://img.shields.io/github/release/kriskbx/whatsapp-sharing.svg)](https://github.com/kriskbx/whatsapp-sharing) [![GitHub license](https://img.shields.io/github/license/kriskbx/whatsapp-sharing.svg)](https://github.com/kriskbx/whatsapp-sharing/blob/master/LICENSE) [![Npm](https://img.shields.io/npm/dm/whatsapp-sharing.svg)](https://www.npmjs.com/package/whatsapp-sharing)


## Installation

### 1. Download

* With Npm: `npm install whatsapp-sharing`
* With Bower: `bower install whatsapp-sharing`
* With Git: `git clone https://github.com/kriskbx/whatsapp-sharing.git`
* Manually: [https://github.com/kriskbx/whatsapp-sharing/releases](https://github.com/kriskbx/whatsapp-sharing/releases) 

Or include the hosted version on [jsdelivr](http://www.jsdelivr.com/): `//cdn.jsdelivr.net/whatsapp-sharing/1.3.3/whatsapp-button.js`

### 2. Integrate the buttons source

Use this code right before the `</body>`, replace `http://your-domain.tld/path/whatsapp-button.js` with the url to the just uploaded file.

	<script type="text/javascript">	if(typeof wabtn4fg==="undefined")	{wabtn4fg=1;h=document.head||document.getElementsByTagName("head")[0],s=document.createElement("script");s.type="text/javascript";s.src="http://your-domain.tld/path/whatsapp-button.js";h.appendChild(s)}</script>

### 3. Place it on your website

Place this code somewhere on your website to display the button:

	<a href="whatsapp://send" data-text="Take a look at this awesome website:" data-href="" class="wa_btn wa_btn_s" style="display:none">Share</a>
	
If you want to customize the size, style, url or the sharing text, feel free to visit [whatsapp-sharing.com](http://www.whatsapp-sharing.com) for a code generator.

## FAQ

### 1. I'm using AJAX?

Run `WASHAREBTN.crBtn();` after you loaded your content.

### 2. I want to track clicks on the button.

You can simply use JavaScript event handlers like `onClick` in the code of step 3.

{'fraction_non_alphanumeric': 0.1693324802729793, 'fraction_numerical': 0.005544892301130305, 'mean_word_length': 5.245006657789614, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 30, 'lorem ipsum': 0, 'www.': 8, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7401656', 'n_tokens_mistral': 1766, 'n_tokens_neox': 1619, 'n_words': 312}