vue鼠标悬停事件实例详解

具体代码如下所述:

v-bind:title="message"

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>vue实例化</title>
</head>
  <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<body>
<div id="app-2">
 <span v-bind:title="message">
  鼠标悬停几秒钟查看此处动态绑定的提示信息!
 </span>
</div>
<script type="text/javascript">
var app2 = new Vue({
 el: '#app-2',
 data: {
  message: '页面加载于 ' + new Date().toLocaleString()
 }
})
</script>
</body>
</html>

总结