Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/api/sfc-script-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,7 @@ const myRef = ref()
</template>
```

Also note that, as when using `withDefaults` with `defineProps`, default values for mutable reference types (like arrays or objects) should be wrapped in functions in `defineModel` to avoid accidental modification and external side effects.
Comment thread
whysopaul marked this conversation as resolved.
Outdated
:::

### Modifiers and Transformers {#modifiers-and-transformers}
Expand Down
1 change: 1 addition & 0 deletions src/guide/components/v-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ const myRef = ref()
</template>
```

Also note that, as when using `withDefaults` with `defineProps`, default values for mutable reference types (like arrays or objects) should be wrapped in functions in `defineModel` to avoid accidental modification and external side effects.
Comment thread
whysopaul marked this conversation as resolved.
Outdated
:::

</div>
Expand Down