We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 849c26c + a9a5030 commit 7fad1c8Copy full SHA for 7fad1c8
guide/in-source.md
@@ -17,7 +17,7 @@ Vitest 还提供了一种方式,可以运行与你的代码实现放在一起
17
首先,在 `if (import.meta.vitest)` 代码块内写一些测试代码并放在文件的末尾,例如:
18
19
```ts [src/index.ts]
20
-// the implementation
+// 执行
21
export function add(...args: number[]) {
22
return args.reduce((a, b) => a + b, 0)
23
}
@@ -82,7 +82,7 @@ export default defineBuildConfig({
82
// [!code ++]
83
'import.meta.vitest': 'undefined', // [!code ++]
84
}, // [!code ++]
85
- // other options
+ // 其他选项
86
})
87
```
88
@@ -100,7 +100,7 @@ export default {
100
101
}), // [!code ++]
102
],
103
104
105
106
0 commit comments