Skip to content

Commit aa9fc38

Browse files
authored
docs: improve common errors formatting and fix typos (#9564)
1 parent 6d39aa3 commit aa9fc38

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

docs/guide/common-errors.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ title: Common Errors | Guide
88

99
If you receive an error that module cannot be found, it might mean several different things:
1010

11-
- 1. You misspelled the path. Make sure the path is correct.
11+
1. You misspelled the path. Make sure the path is correct.
1212

13-
- 2. It's possible that you rely on `baseUrl` in your `tsconfig.json`. Vite doesn't take into account `tsconfig.json` by default, so you might need to install [`vite-tsconfig-paths`](https://www.npmjs.com/package/vite-tsconfig-paths) yourself, if you rely on this behaviour.
13+
2. It's possible that you rely on `baseUrl` in your `tsconfig.json`. Vite doesn't take into account `tsconfig.json` by default, so you might need to install [`vite-tsconfig-paths`](https://www.npmjs.com/package/vite-tsconfig-paths) yourself, if you rely on this behavior.
1414

1515
```ts
1616
import { defineConfig } from 'vitest/config'
@@ -28,7 +28,7 @@ Or rewrite your path to not be relative to root:
2828
+ import helpers from '../src/helpers'
2929
```
3030

31-
- 3. Make sure you don't have relative [aliases](/config/#alias). Vite treats them as relative to the file where the import is instead of the root.
31+
3. Make sure you don't have relative [aliases](/config/#alias). Vite treats them as relative to the file where the import is instead of the root.
3232

3333
```ts
3434
import { defineConfig } from 'vitest/config'
@@ -47,7 +47,7 @@ export default defineConfig({
4747

4848
This error can happen when NodeJS's `fetch` is used with default [`pool: 'threads'`](/config/#threads). This issue is tracked on issue [Timeout abort can leave process(es) running in the background #3077](https://github.com/vitest-dev/vitest/issues/3077).
4949

50-
As work-around you can switch to [`pool: 'forks'`](/config/#forks) or [`pool: 'vmForks'`](/config/#vmforks).
50+
As a workaround, you can switch to [`pool: 'forks'`](/config/#forks) or [`pool: 'vmForks'`](/config/#vmforks).
5151

5252
::: code-group
5353
```ts [vitest.config.js]
@@ -120,7 +120,7 @@ Running [native NodeJS modules](https://nodejs.org/api/addons.html) in `pool: 't
120120
- `Abort trap: 6`
121121
- `internal error: entered unreachable code`
122122

123-
In these cases the native module is likely not built to be multi-thread safe. As work-around, you can switch to `pool: 'forks'` which runs the test cases in multiple `node:child_process` instead of multiple `node:worker_threads`.
123+
In these cases the native module is likely not built to be multi-thread safe. As a workaround, you can switch to `pool: 'forks'` which runs the test cases in multiple `node:child_process` instead of multiple `node:worker_threads`.
124124

125125
::: code-group
126126
```ts [vitest.config.js]

0 commit comments

Comments
 (0)