Vize

vue/no-console

Disallow console access 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 template event expression calls console.log.

<template>
  <button @click="console.log(value)">Save</button>
</template>

Good

The template delegates logging to a script binding.

<template>
  <button @click="logValue">Save</button>
</template>

Configuration (Vite+)

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

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

Then run vp run lint.