简介
html引入Vue
代码演示
<html>
<head>
<title>html 引入 Vue</title>
</head>
<body>
<div id = "app">
<!-- 插值表达式 -->
{{ message }}
</div>
<h1>{{count}}</h1>
<script type="module">
import { createApp, ref } from 'https://unpkg.com/vue@3/dist/vue.esm-browser.js'
createApp({
data(){
return {
message: 'Hello Vue!',
count: 150
}
}
}).mount('#app')
</script>
</body>
</html>
效果

