You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+48-18Lines changed: 48 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,33 +13,30 @@ compiler).
13
13
14
14
## Index
15
15
16
+
-[Demo](#demo)
16
17
-[Install](#install)
17
18
-[Usage](#usage)
18
19
-[Documentation](#documentation)
19
20
-[Benchmarks](#benchmarks)
20
21
-[Tests](#tests)
21
22
23
+
## Demo
24
+
25
+
[Live demo on CodePen.](https://codepen.io/trusktr/pen/abMLVxa?editors=1010)
26
+
22
27
## Install
23
28
29
+
### Local Install
30
+
24
31
Install using NPM:
25
32
26
33
```sh
27
34
npm install @lume/kiwi
28
35
```
29
36
30
-
then import it into your project:
31
-
32
-
```js
33
-
import*askiwifrom'@lume/kiwi'
34
-
35
-
console.log(kiwi)
36
-
37
-
// ...use kiwi...
38
-
```
39
-
40
37
If you have a plain web app with no build, or a non-browser JS runtime that also
41
38
supports import maps like Deno, you'll need to add `@lume/kiwi` to your
42
-
`importmap` script so that the browser knows where to import kiwi from. F.e.
39
+
`importmap` script so that the browser or JS runtime knows where to import kiwi from. F.e.
43
40
something like this:
44
41
45
42
```html
@@ -52,8 +49,32 @@ something like this:
52
49
</script>
53
50
```
54
51
52
+
### CDN Install
53
+
54
+
Note, if using importmaps and native ES Modules in a browser, or in a JS runtime like Deno, you can get Kiwi directly from the UNPKG CDN without installing it locally (just as the [live CodePen demo](#demo) does):
0 commit comments