Vize

vue/no-define-model-default

Disallow default values in defineModel.

Default severity Presets Automatic fix Options
warning None No None

Applies to: Vue SFC templates and blocks, with script context where the rule requires it.

Bad

The child model declares a default that can desynchronize the parent.

<script setup>
const model = defineModel({ default: "draft" })
</script>
<template />

Good

The parent supplies the initial model value instead.

<script setup lang="ts">
const model = defineModel<string>()
</script>
<template />

Configuration (Vite+)

import { defineConfig } from "@vizejs/vite-plugin/vite-plus";

export default defineConfig({}).withVue({
  linter: {
    "preset": "incremental",
    "rules": {
      "vue/no-define-model-default": "warn"
    }
  },
});

Then run vp run lint.