mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-18 17:35:57 +00:00
docs: resolve many twoslash errors (#30573)
This commit is contained in:
parent
18c85e5039
commit
2693dc2914
@ -174,6 +174,7 @@ Under the hood, `mountSuspended` wraps `mount` from `@vue/test-utils`, so you ca
|
|||||||
For example:
|
For example:
|
||||||
|
|
||||||
```ts twoslash
|
```ts twoslash
|
||||||
|
// @noErrors
|
||||||
import { it, expect } from 'vitest'
|
import { it, expect } from 'vitest'
|
||||||
import type { Component } from 'vue'
|
import type { Component } from 'vue'
|
||||||
declare module '#components' {
|
declare module '#components' {
|
||||||
@ -194,6 +195,7 @@ it('can mount some component', async () => {
|
|||||||
```
|
```
|
||||||
|
|
||||||
```ts twoslash
|
```ts twoslash
|
||||||
|
// @noErrors
|
||||||
import { it, expect } from 'vitest'
|
import { it, expect } from 'vitest'
|
||||||
// ---cut---
|
// ---cut---
|
||||||
// tests/components/SomeComponents.nuxt.spec.ts
|
// tests/components/SomeComponents.nuxt.spec.ts
|
||||||
@ -225,6 +227,7 @@ The passed in component will be rendered inside a `<div id="test-wrapper"></div>
|
|||||||
Examples:
|
Examples:
|
||||||
|
|
||||||
```ts twoslash
|
```ts twoslash
|
||||||
|
// @noErrors
|
||||||
import { it, expect } from 'vitest'
|
import { it, expect } from 'vitest'
|
||||||
import type { Component } from 'vue'
|
import type { Component } from 'vue'
|
||||||
declare module '#components' {
|
declare module '#components' {
|
||||||
@ -243,6 +246,7 @@ it('can render some component', async () => {
|
|||||||
```
|
```
|
||||||
|
|
||||||
```ts twoslash
|
```ts twoslash
|
||||||
|
// @noErrors
|
||||||
import { it, expect } from 'vitest'
|
import { it, expect } from 'vitest'
|
||||||
// ---cut---
|
// ---cut---
|
||||||
// tests/App.nuxt.spec.ts
|
// tests/App.nuxt.spec.ts
|
||||||
|
Loading…
Reference in New Issue
Block a user