<commit_before># Build Process

_📖  [Please see `bin/README.md`](../bin/README.md) For a list of `bin` scripts used within the build pipeline._


## `snuggsi.min.es.br`

*Mime Type* : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

*Weight* : ~ 1,300 OCTETS _(1.3kiloBytes)_


## `snuggsi.min.js.br`

*Mime Type* : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_

*Weight* : ~ 1,400 OCTETS _(1.4kiloBytes)_


## Glossary
  - [Content Negotiation](https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_negotiation)
  - [Javascript MIME types](https://html.spec.whatwg.org/#javascript-mime-type)
  - [Scripting Media Types _(rfc4329)_](https://www.rfc-editor.org/rfc/rfc4329.txt)
  - [WHATWG/W3c approval of media types](https://github.com/w3c/webcomponents/issues/645#issuecomment-317338144)
  - [why you should know `application/ecmascript`](https://stackoverflow.com/questions/9664282/difference-between-application-x-javascript-and-text-javascript-content-types)
  - [Difference between Ethernet frame and Packet](https://www.youtube.com/watch?v=wcSee63SIlg)
  - [MTU _(Maximum Transmission Unit)_](https://en.wikipedia.org/wiki/Maximum_transmission_unit)
  - [_(Ethernet)_ Frame](https://en.wikipedia.org/wiki/Ethernet_frame)
  - [OCTET](https://en.wikipedia.org/wiki/Octet_(computing))


## Pipeline

### ECMAScript Bundle (snuggsi.es)
Mime Type : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

#### snuggsi.es _(bundled)_
  - Uses [cat](https://en.wikipedia.org/wiki/Cat_(Unix)) command
for creating [ECMAScript](https://en.wikipedia.org/wiki/ECMAScript) bundle.

`elements/*.es` ➡️  `snuggsi.es`


### ECMAScript 5 Transpilation (snuggsi.js)
Mime Type : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_

File Extension: `.js`

#### snuggsi.js
  - Uses [buble.js](http://buble.surge.sh)

`snuggsi.es` ➡️  `snuggsi.js`


### Minification _(snuggsi.min.es)_ &amp; _(snuggsi.min.js)_ 
Mime Type : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

Mime Type : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_


#### `snuggsi.es` ➡️  `snuggsi.min.es`
_(Uses [Uses `uglify-es`](https://github.com/mishoo/UglifyJS2/tree/harmony))_

#### `snuggsi.js` ➡️  `snuggsi.min.js`
_(Uses [UglifyJS](https://github.com/mishoo/UglifyJS))_


### Compression

⚠️ Please read why Internet Explorer won't let `DEFLATE` be great.
[here](https://blogs.msdn.microsoft.com/ieinternals/2014/10/21/compressing-the-web/)
,[here](https://support.microsoft.com/en-us/help/837251/internet-explorer-does-not-correctly-decompress-data-that-uses-the-gzip)
, [here](https://stackoverflow.com/questions/883841/why-do-real-world-servers-prefer-gzip-over-deflate-encoding#answer-1579506)
,and [here](https://zoompf.com/blog/2012/02/lose-the-wait-http-compression)
⚠️

**snuggsi** handles the following content encoding tokens:
  - `brotli`
  - `gzip`
  - `deflate` _(zlib)_

  - [HTTP Compression](https://en.wikipedia.org/wiki/HTTP_compression)
  - [Accept-Encoding](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Encoding)
  - [Content-Encoding](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Encoding)
  - [Content-Encoding Tokens](https://en.wikipedia.org/wiki/HTTP_compression#Content-Encoding_tokens)
  - [Comparison of Brotli, Deflate, Zopfli, LZMA, LZHAM
  and Bzip2 Compression Algorithms](https://cran.r-project.org/web/packages/brotli/vignettes/brotli-2015-09-22.pdf)
  - [Great article on compression](https://blog.cloudflare.com/results-experimenting-brotli)
Links
  - DEFLATE format - https://en.wikipedia.org/wiki/DEFLATE
  - [rfc1951](https://tools.ietf.org/html/rfc1951)


#### Brotli Compression _(snuggsi.min.br)_

`snuggsi.min.es` ➡️  `snuggsi.min.es.br`

`snuggsi.min.js` ➡️  `snuggsi.min.js.br`

Links
- http://caniuse.com/#search=brotli
- https://en.wikipedia.org/wiki/Brotli
- https://certsimple.com/blog/nginx-brotli
- https://blogs.akamai.com/2016/02/understanding-brotlis-potential.html
- https://hacks.mozilla.org/2015/11/better-than-gzip-compression-with-brotli

Server Support
- Ruby _(brotli)_ - https://github.com/miyucy/brotli
- Node _(brotli)_ - https://www.npmjs.com/package/brotli
- Node _(iltrob)_ - https://github.com/MayhemYDG/iltorb
- Koa _(koa-send)_ - https://github.com/koajs/send
- Express _(shrink-ray)_ - https://github.com/aickin/shrink-ray
- NGINX _(ngx_brotli)_ - https://github.com/google/ngx_brotli
- Apache _(mod_brotli)_ - https://httpd.apache.org/docs/trunk/mod/mod_brotli.html
- IIS _(IIS Brotli)_ - https://www.iis.net/downloads/community/2016/03/iis-brotli

Browser Support
- http://caniuse.com/#search=brotli
- Google Chrome has supported Brotli since version 49
- Microsoft Edge supports Brotli since version 15<commit_msg>Add brotli compression rfc spec<commit_after># Build Process

_📖  [Please see `bin/README.md`](../bin/README.md) For a list of `bin` scripts used within the build pipeline._


## `snuggsi.min.es.br`

*Mime Type* : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

*Weight* : ~ 1,300 OCTETS _(1.3kiloBytes)_


## `snuggsi.min.js.br`

*Mime Type* : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_

*Weight* : ~ 1,400 OCTETS _(1.4kiloBytes)_


## Glossary
  - [Content Negotiation](https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_negotiation)
  - [Javascript MIME types](https://html.spec.whatwg.org/#javascript-mime-type)
  - [Scripting Media Types _(rfc4329)_](https://www.rfc-editor.org/rfc/rfc4329.txt)
  - [WHATWG/W3c approval of media types](https://github.com/w3c/webcomponents/issues/645#issuecomment-317338144)
  - [why you should know `application/ecmascript`](https://stackoverflow.com/questions/9664282/difference-between-application-x-javascript-and-text-javascript-content-types)
  - [Difference between Ethernet frame and Packet](https://www.youtube.com/watch?v=wcSee63SIlg)
  - [MTU _(Maximum Transmission Unit)_](https://en.wikipedia.org/wiki/Maximum_transmission_unit)
  - [_(Ethernet)_ Frame](https://en.wikipedia.org/wiki/Ethernet_frame)
  - [OCTET](https://en.wikipedia.org/wiki/Octet_(computing))


## Pipeline

### ECMAScript Bundle (snuggsi.es)
Mime Type : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

#### snuggsi.es _(bundled)_
  - Uses [cat](https://en.wikipedia.org/wiki/Cat_(Unix)) command
for creating [ECMAScript](https://en.wikipedia.org/wiki/ECMAScript) bundle.

`elements/*.es` ➡️  `snuggsi.es`


### ECMAScript 5 Transpilation (snuggsi.js)
Mime Type : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_

File Extension: `.js`

#### snuggsi.js
  - Uses [buble.js](http://buble.surge.sh)

`snuggsi.es` ➡️  `snuggsi.js`


### Minification _(snuggsi.min.es)_ &amp; _(snuggsi.min.js)_ 
Mime Type : `application/ecmascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-8.2))_

Mime Type : `application/javascript` _([Specification](https://tools.ietf.org/html/rfc4329#section-7.2))_


#### `snuggsi.es` ➡️  `snuggsi.min.es`
_(Uses [Uses `uglify-es`](https://github.com/mishoo/UglifyJS2/tree/harmony))_

#### `snuggsi.js` ➡️  `snuggsi.min.js`
_(Uses [UglifyJS](https://github.com/mishoo/UglifyJS))_


### Compression

⚠️ Please read why Internet Explorer won't let `DEFLATE` be great.
[here](https://blogs.msdn.microsoft.com/ieinternals/2014/10/21/compressing-the-web/)
,[here](https://support.microsoft.com/en-us/help/837251/internet-explorer-does-not-correctly-decompress-data-that-uses-the-gzip)
, [here](https://stackoverflow.com/questions/883841/why-do-real-world-servers-prefer-gzip-over-deflate-encoding#answer-1579506)
,and [here](https://zoompf.com/blog/2012/02/lose-the-wait-http-compression)
⚠️

**snuggsi** handles the following content encoding tokens:
  - `brotli`
  - `gzip`
  - `deflate` _(zlib)_

  - [HTTP Compression](https://en.wikipedia.org/wiki/HTTP_compression)
  - [Accept-Encoding](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Encoding)
  - [Content-Encoding](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Encoding)
  - [Content-Encoding Tokens](https://en.wikipedia.org/wiki/HTTP_compression#Content-Encoding_tokens)
  - [Comparison of Brotli, Deflate, Zopfli, LZMA, LZHAM
  and Bzip2 Compression Algorithms](https://cran.r-project.org/web/packages/brotli/vignettes/brotli-2015-09-22.pdf)
  - [Great article on compression](https://blog.cloudflare.com/results-experimenting-brotli)
Links
  - DEFLATE format - https://en.wikipedia.org/wiki/DEFLATE
  - [rfc1951](https://tools.ietf.org/html/rfc1951)


#### Brotli Compression _(snuggsi.min.br)_

`snuggsi.min.es` ➡️  `snuggsi.min.es.br`

`snuggsi.min.js` ➡️  `snuggsi.min.js.br`

Links
- [Brotli Compressed Data Format _(rfc7932)_](https://tools.ietf.org/html/rfc7932)
- http://caniuse.com/#search=brotli
- https://en.wikipedia.org/wiki/Brotli
- https://certsimple.com/blog/nginx-brotli
- https://blogs.akamai.com/2016/02/understanding-brotlis-potential.html
- https://hacks.mozilla.org/2015/11/better-than-gzip-compression-with-brotli

Server Support
- Ruby _(brotli)_ - https://github.com/miyucy/brotli
- Node _(brotli)_ - https://www.npmjs.com/package/brotli
- Node _(iltrob)_ - https://github.com/MayhemYDG/iltorb
- Koa _(koa-send)_ - https://github.com/koajs/send
- Express _(shrink-ray)_ - https://github.com/aickin/shrink-ray
- NGINX _(ngx_brotli)_ - https://github.com/google/ngx_brotli
- Apache _(mod_brotli)_ - https://httpd.apache.org/docs/trunk/mod/mod_brotli.html
- IIS _(IIS Brotli)_ - https://www.iis.net/downloads/community/2016/03/iis-brotli

Browser Support
- http://caniuse.com/#search=brotli
- Google Chrome has supported Brotli since version 49
- Microsoft Edge supports Brotli since version 15
{'fraction_non_alphanumeric': 0.17848240103699273, 'fraction_numerical': 0.03130920331039984, 'mean_word_length': 4.5846325167037865, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 87, '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': '4959871', 'n_tokens_mistral': 4175, 'n_tokens_neox': 3918, 'n_words': 496}