💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
## 语法: `v-on` 简写@ ``` <div @:click="handleClick">{{msg}}</div> 等同于 <div v-on:click="handleClick">{{msg}}</div> ``` ## 代码案例以及语法: ~~~ <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Title</title> <script src="vue/vue.js"></script> </head> <body> <div id="box"> <div v-on:click="handleClick">{{msg}}</div> </div> </body> </html> <script type="text/javascript"> new Vue({ el:"#box", data:{ msg:"hello word" }, methods:{ handleClick:function (){ this.msg="hello" } } }) </script> ~~~