Vize

vue/no-negated-condition

Disallow negated ternary conditions in template expressions.

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 ternary starts with a negated condition.

<template>
  <p>{{ !ready ? fallback : primary }}</p>
</template>

Good

The positive condition and branch order communicate the choice directly.

<template>
  <p>{{ ready ? primary : fallback }}</p>
</template>

Configuration (Vite+)

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

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

Then run vp run lint.