<commit_before># aload.js [![Build Status](https://secure.travis-ci.org/pazguille/aload.png)](http://travis-ci.org/pazguille/aload) [![devDependency Status](https://david-dm.org/pazguille/aload/dev-status.png)](https://david-dm.org/pazguille/aload#info=devDependencies)

> Loads images, background images, scripts, styles, iframes, videos and audios asynchronously (just 260 bytes).

## API

### aload([nodeList])
Loads images, background images, scripts, styles, iframes, videos and audios asynchronously.
- `nodeList` {NodeList} [optional] - A NodeList of elements. By default, it is the result of `querySelectorAll('[data-aload]')`.

```js
aload();
```

## Installation

    $ npm install aload

As standalone just include `aload` function (just 260 bytes) inline into your HTML file:

```html
<script>
  function aload(t){"use strict";t=t||window.document.querySelectorAll("[data-aload]"),void 0===t.length&&(t=[t]);var a,e=0,r=t.length;for(e;r>e;e+=1)a=t[e],a["LINK"!==a.tagName?"src":"href"]=a.getAttribute("data-aload"),a.removeAttribute("data-aload");return t}
</script>
```

## Usage

1. You should use `data-aload` attributes instead of `src` or `href` in your HTML tags (an image for example):

  ```html
  <img data-aload="http://foobar.com/foo.png" width="400" height="300">
  ```
  - `data-aload` - URL of the source.

2. Now, you can start to load your images asynchronously!

  ```js
  // Onload
  window.onload = function () {
    aload();
  };
  ```

### You can load everything asynchronously.

- images
- background images
- scripts
- styles
- iframes<commit_msg>Update README aload size and snippet.<commit_after># aload.js [![Build Status](https://secure.travis-ci.org/pazguille/aload.png)](http://travis-ci.org/pazguille/aload) [![devDependency Status](https://david-dm.org/pazguille/aload/dev-status.png)](https://david-dm.org/pazguille/aload#info=devDependencies)

> Loads images, background images, scripts, styles, iframes, videos and audios asynchronously (just 260 bytes).

## API

### aload([nodeList])
Loads images, background images, scripts, styles, iframes, videos and audios asynchronously.
- `nodeList` {NodeList} [optional] - A NodeList of elements. By default, it is the result of `querySelectorAll('[data-aload]')`.

```js
aload();
```

## Installation

    $ npm install aload

As standalone just include `aload` function (just 241 bytes) inline into your HTML file:

```html
<script>
  function aload(t){"use strict";var e="data-aload";return t=t||window.document.querySelectorAll("["+e+"]"),void 0===t.length&&(t=[t]),[].forEach.call(t,function(t){t["LINK"!==t.tagName?"src":"href"]=t.getAttribute(e),t.removeAttribute(e)}),t}
</script>
```

## Usage

1. You should use `data-aload` attributes instead of `src` or `href` in your HTML tags (an image for example):

  ```html
  <img data-aload="http://foobar.com/foo.png" width="400" height="300">
  ```
  - `data-aload` - URL of the source.

2. Now, you can start to load your images asynchronously!

  ```js
  // Onload
  window.onload = function () {
    aload();
  };
  ```

### You can load everything asynchronously.

- images
- background images
- scripts
- styles
- iframes
{'fraction_non_alphanumeric': 0.17628508356985179, 'fraction_numerical': 0.010091453800063072, 'mean_word_length': 4.809523809523809, 'pattern_counts': {'":': 2, '<': 9, '<?xml version=': 0, '>': 12, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '845721', 'n_tokens_mistral': 1135, 'n_tokens_neox': 1086, 'n_words': 270}