···2626If you are using TypeScript, since Vitest 0.31.0 you can extend default `Assertion` interface in an ambient declaration file (e.g: `vitest.d.ts`) with the code below:
27272828```ts
2929+import type { Assertion, AsymmetricMatchersContaining } from 'vitest'
3030+2931interface CustomMatchers<R = unknown> {
3032 toBeFoo(): R
3133}