v-text
Updated on Sep 5, 2025 1 minutes to readThe v-text directive sets the text content of an element.
It takes a string and replaces the element’s content with plain text, escaping any HTML.
• Example
<div v-text="'<h1>Title</h1><p>Some text.</p>'"></div>
<!-- Result:
<h1>Title</h1><p>Some text.</p>
-->