Skip to content

Commit dbc5cb8

Browse files
committed
docs: describe the usage of BigInt
1 parent 3b38ee8 commit dbc5cb8

File tree

2 files changed

+40
-2
lines changed

2 files changed

+40
-2
lines changed

README.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
- Deserialize with [destr](https://github.com/unjs/destr) by default, up to 35.96x faster than `JSON.parse`
4646
- 💪 Powerful
4747
- View, edit, format, validate, compact, sort, query, filter, transform, repair, highlight JSON
48-
- 7 primitive data types including `BigInt` and `Symbol`
48+
- 7 primitive data types including [BigInt](#bigint) and `Symbol`
4949
- 3 edit modes: text mode & tree mode & table mode
5050
- 2 themes: light theme & dark theme
5151
- 2-way binding: [parsed or stringified JSON](#parsed-json-vs-stringified-json)
@@ -1036,6 +1036,25 @@ onMounted(() => {
10361036

10371037
<br>
10381038

1039+
## BigInt
1040+
1041+
```shell
1042+
npm i lossless-json
1043+
```
1044+
1045+
```vue
1046+
<script setup>
1047+
import JsonEditorVue from 'json-editor-vue'
1048+
import { parse, stringify } from 'lossless-json'
1049+
</script>
1050+
1051+
<template>
1052+
<JsonEditorVue :parser="{ parse, stringify }" />
1053+
</template>
1054+
```
1055+
1056+
<br>
1057+
10391058
## Dark Theme
10401059

10411060
```vue

docs/README.zh-CN.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
- 反序列化默认使用 [destr](https://github.com/unjs/destr),比 `JSON.parse` 快达 35.96 倍
4646
- 💪 强力
4747
- 预览、编辑、格式化、校验、压缩、排序、查询、过滤、转换、修复、高亮 JSON
48-
- 7 种原始数据类型包括 `BigInt` and `Symbol`
48+
- 7 种原始数据类型包括 [BigInt](#bigint) and `Symbol`
4949
- 3 种编辑模式:文本模式 & 树形模式 & 表格模式
5050
- 2 种主题:浅色主题 & 深色主题
5151
- 双向绑定:[parsed 或 stringified JSON](#parsed-json-vs-stringified-json)
@@ -1034,6 +1034,25 @@ onMounted(() => {
10341034

10351035
<br>
10361036

1037+
## BigInt
1038+
1039+
```shell
1040+
npm i lossless-json
1041+
```
1042+
1043+
```vue
1044+
<script setup>
1045+
import JsonEditorVue from 'json-editor-vue'
1046+
import { parse, stringify } from 'lossless-json'
1047+
</script>
1048+
1049+
<template>
1050+
<JsonEditorVue :parser="{ parse, stringify }" />
1051+
</template>
1052+
```
1053+
1054+
<br>
1055+
10371056
## 暗色主题
10381057

10391058
```vue

0 commit comments

Comments
 (0)