[Image dump the chain fails, the source station may have security chain mechanism, it is recommended to save the picture down uploaded directly (img-YJ6SPNTm-1585505076954) ( file: /// C: / Users /% E6% 96% B9% E7% the AF E4%%% 82% B0 B8 / AppData / Roaming / Tencent / QQ / the Temp / 28% D G @% 5B8HQGJ% 280XS1J [email protected])] a, VUE example
introduced debug version VUE
Into the production version of the VUE
Also enter the official website to download js file to import, import head
VUE first page attribute el +
el mount point, data in the data mount point on the graph data into ID = app Tags of {{message}}, curly brackets interpolation expression syntax is formula.
Examples vue scope of the label mount with all sub-tab.
data Data
VUE data defined in the data, the data may be data in the data strings, numbers, arrays, dictionaries and the like.
Second, local application instructions V- VUE
v-text
content for the Settings tab, the tab for replacing all of the content, when we want to replace the part, we use an interpolation expression.
v-html
When data is written as plaintext, the same v-text and v-html rendering effects, when data is written as an html tag, v-html will have special effects.
When using the v-text would be interpreted as normal text, when using the v-html data will be interpreted as html tags
v-ON
v ON-label binding instructions for the event, the event write methods dictionary vue instance, the and passes the name of the event to the v-on: = trigger event "event name"
@ can replace the v-on:
the click a mouse click event
dblclick to double click event
when we click on the h2 tag, we will trigger changefood function, binding function of the value of the food, then we change the food value in the function, the data is rendered to the html page, h2 at this time to change the text of the page.
Counter Instance
Two button num adjustment value, a function written in the example of vue
using this adjustment value num present example
cut from: https:? //Www.bilibili.com/video/BV12J411m7MG p = 10