Skip to content

Commit

Permalink
docs: Add installation docs in browsers
Browse files Browse the repository at this point in the history
  • Loading branch information
raon0211 committed Jul 20, 2024
1 parent 528bc2b commit b19773d
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 0 deletions.
22 changes: 22 additions & 0 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,25 @@ es-toolkit is also available on Bun. You can install it via the following comman
```sh
bun add es-toolkit
```

## Browsers

You can find es-toolkit on CDNs such as [jsdelivr](https://www.jsdelivr.com) or [unpkg](https://unpkg.com). We define `_` to include all functions, similar to Lodash.

::: code-group

```html [jsdelivr]
<script src="https://cdn.jsdelivr.net/npm/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

```html [unpkg]
<script src="https://unpkg.com/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

:::
22 changes: 22 additions & 0 deletions docs/ko/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,25 @@ es-toolkit은 Bun에서도 사용할 수 있어요. 아래 명령어를 사용
```sh
bun add es-toolkit
```

## 브라우저

[jsdelivr](https://www.jsdelivr.com) 또는 [unpkg](https://unpkg.com) 같은 CDN에서 es-toolkit을 쓸 수 있어요. Lodash와 같이 `_` 변수에 모든 함수가 포함돼요.

::: code-group

```html [jsdelivr]
<script src="https://cdn.jsdelivr.net/npm/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

```html [unpkg]
<script src="https://unpkg.com/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

:::
22 changes: 22 additions & 0 deletions docs/zh_hans/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,25 @@ es-toolkit 也支持 Bun。您可以使用以下命令安装它:
```sh
bun add es-toolkit
```

## 浏览器

你可以在诸如[jsdelivr](https://www.jsdelivr.com)[unpkg](https://unpkg.com)等CDN上找到es-toolkit。我们将 `_` 定义为包含所有函数,类似于 Lodash。

::: code-group

```html [jsdelivr]
<script src="https://cdn.jsdelivr.net/npm/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

```html [unpkg]
<script src="https://unpkg.com/es-toolkit"></script>
<script>
var arr = _.chunk([1, 2, 3, 4, 5, 6], 3);
</script>
```

:::

0 comments on commit b19773d

Please sign in to comment.