Skip to content

Commit fc4082a

Browse files
docs(api): add note for attachTo
Add explanation about mounting mechanism. This information is available in v1 docs, but not in current.
1 parent b6e5b82 commit fc4082a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎docs/api/index.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ attachTo?: HTMLElement | string
8181

8282
Can be a valid CSS selector, or an [`Element`](https://developer.mozilla.org/en-US/docs/Web/API/Element) connected to the document.
8383

84+
Note that the component is appended to the node, it doesn't replace the whole content of the node. If you mount the component on the same node in multiple tests - make sure to unmount it after each test by calling `wrapper.unmount()`, this will remove the rendered elements from the node.
85+
8486
`Component.vue`:
8587

8688
```vue

0 commit comments

Comments
 (0)