src/content/docs/linter/rules/use-vue-valid-v-html.mdx
import { Tabs, TabItem } from '@astrojs/starlight/components';
<Tabs> <TabItem label="HTML" icon="seti:html"> :::caution This rule is part of the [nursery](/linter/#nursery) group. This means that it is experimental and the behavior can change at any time. ::: ## Summary - Rule available since: `v2.3.6` - Diagnostic Category: [`lint/nursery/useVueValidVHtml`](/reference/diagnostics#diagnostic-category) - This rule doesn't have a fix. - The default severity of this rule is [**information**](/reference/diagnostics#information). - This rule belongs to the following domains: - [`vue`](/linter/domains#vue) - Sources: - Same as [`vue/valid-v-html`](https://eslint.vuejs.org/rules/valid-v-html){
"linter": {
"rules": {
"nursery": {
"useVueValidVHtml": "error"
}
}
}
}
Enforce valid v-html directives.
This rule reports v-html directives in the following cases:
<div v-html:aaa></div><div v-html.bbb></div><div v-html></div><div v-html:aaa="foo"></div>
<div v-html.bbb="foo"></div>
<div v-html></div>
<div v-html="htmlContent"></div>