-
-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathindex.js
31 lines (30 loc) · 833 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/**
* rehype plugin to minify language attributes.
*
* ## What is this?
*
* This package is a plugin that can minify the contents of language tags:
* [BCP 47 tags](https://github.com/wooorm/bcp-47).
*
* ## When should I use this?
*
* You can use this plugin when you want to improve the size of HTML documents.
*
* ## API
*
* ### `unified().use(rehypeMinifyLanguage)`
*
* Minify language attributes.
*
* ###### Returns
*
* Transform ([`Transformer`](https://github.com/unifiedjs/unified#transformer)).
*
* @example
* {}
* <span lang="en-US">Color</span>
* <a href="https://nl.wikipedia.org/wiki/HyperText_Markup_Language" hreflang="nld-NL">HTML</a>
* <span xml:lang="pt-BR">ótimo</span>
* <track src="colour.vtt" srclang="en-GB" label="English (UK)">
*/
export {default} from './lib/index.js'