1. v-text text rendering instructions
<div id="test"> <p v-text="message"></p> </div> <script src="./js/vue.js"></script> <script> const vm = new Vue({ el:"#test", data:{ message:"<h2>hello vue</h2>" } }) </script> The output is: 2. v-html
<div id="test"> <p v-html="message"></p> </div> <script src="./js/vue.js"></script> <script> const vm = new Vue({ el:"#test", data:{ message:"<h2>hello vue</h2>" } }) </script> The output is: This is the end of this article about the Vue directives v-html and v-text. For more related v-html and v-text content, please search for previous articles on 123WORDPRESS.COM or continue to browse the related articles below. I hope everyone will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: Detailed explanation of the difference between device-width and width in CSS3 media queries
>>: Use js in html to get the local system time
In HTML, the <img> tag is used to define an...
MySQL database too many connections This error ob...
1. Radio grouping As long as the name is the same,...
This article records the complete uninstallation ...
Recently, when using kazam in Ubuntu 20.04 for re...
Preface I always thought that UTF-8 was a univers...
What is Nginx access restriction configuration Ng...
Problem Description Several machines recently dis...
Preface The location in the server block in the N...
Preface These principles are summarized from actu...
Table of contents Problem Description Principle A...
Preface: In the previous article, we mainly intro...
Simply put, delayed replication is to set a fixed...
Table of contents question analyze solve Replace ...
One environment Install VMware Tools on CentOS 7 ...