Skip to content

Commit c39cdd6

Browse files
committed
📝docs: 更新文档内容,优化示例代码和图片
在文档中更新了数学公式的排版,移除了多余的图片引用,确保内容的简洁性和可读性。同时,添加了新的代码示例,展示了vitepress的配置用法,提升了文档的实用性和用户体验。
1 parent e21793a commit c39cdd6

2 files changed

Lines changed: 36 additions & 13 deletions

File tree

docs/文档/5-示例展示.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,4 @@ $$ x = {-b \pm \sqrt{b^2-4ac} \over 2a} $$
8484
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- |
8585
| $\nabla \cdot \vec{\mathbf{B}} = 0$ | divergence of $\vec{\mathbf{B}}$ is zero |
8686
| $\nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} = \vec{\mathbf{0}}$ | curl of $\vec{\mathbf{E}}$ is proportional to the rate of change of $\vec{\mathbf{B}}$ |
87-
| $\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} = \frac{4\pi}{c}\vec{\mathbf{j}} \nabla \cdot \vec{\mathbf{E}} = 4 \pi \rho$ | _wha?_ |
88-
89-
![效果图](https://i.theojs.cn/logo/Lumen-Logo.webp)
90-
91-
![浅色模式{.light-only}](https://i.theojs.cn/logo/github.svg)
92-
93-
![深色模式{.dark-only}](https://i.theojs.cn/logo/github-dark.svg)
94-
95-
![深色模式](https://i.theojs.cn/logo/github-dark.svg#dark)
96-
97-
![浅色模式](https://i.theojs.cn/logo/github.svg#light)
87+
| $\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} = \frac{4\pi}{c}\vec{\mathbf{j}} \nabla \cdot \vec{\mathbf{E}} = 4 \pi \rho$ | _wha?_ |

docs/文档/8-api-examples.md

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
---
2-
title: api-examples
3-
order: 7
42
outline: deep
53
---
64

@@ -49,3 +47,38 @@ const { site, theme, page, frontmatter } = useData()
4947
## More
5048

5149
Check out the documentation for the [full list of runtime APIs](https://vitepress.dev/reference/runtime-api#usedata).
50+
51+
::: code-group
52+
53+
```js [config.js]
54+
/**
55+
* @type {import('vitepress').UserConfig}
56+
*/
57+
const config = {
58+
// ...
59+
}
60+
61+
export default config
62+
```
63+
64+
```ts [config.ts]
65+
import type { UserConfig } from 'vitepress'
66+
67+
const config: UserConfig = {
68+
// ...
69+
}
70+
71+
export default config
72+
```
73+
74+
:::
75+
76+
![效果图](https://i.theojs.cn/logo/Lumen-Logo.webp)
77+
78+
![浅色模式{.light-only}](https://i.theojs.cn/logo/github.svg)
79+
80+
![深色模式{.dark-only}](https://i.theojs.cn/logo/github-dark.svg)
81+
82+
![深色模式](https://i.theojs.cn/logo/github-dark.svg#dark)
83+
84+
![浅色模式](https://i.theojs.cn/logo/github.svg#light)

0 commit comments

Comments
 (0)