Skip to content

Commit fba74c1

Browse files
committed
document $mount() and $destroy() change
1 parent 8a2a7f3 commit fba74c1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

changes.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ vm.$mount('#app') // actually compile the DOM
3030
var vm = new Vue({ el: '#app', data: {a: 1} })
3131
```
3232

33+
If `$mount()` is called with no argument, an empty `<div>` will then be created.
34+
3335
## New Scope Inheritance Model
3436

3537
> Breaking
@@ -578,4 +580,6 @@ Rendered result:
578580

579581
## Misc
580582

583+
- `$destroy()` now by default leaves `$el` intact. If you want to remove it (and trigger transitions), call `$destroy(true)`.
584+
581585
- When there are inline values on input elements bound with `v-model`, e.g. `<input value="hi" v-model="msg">`, the **inline value** will be used as the inital value. If the vm comes with default data, it **will be overwritten** by the inline value. Same for `selected` attribute on `<option>` elements.

0 commit comments

Comments
 (0)