<script src="/static/plugins/vue@2.5.13/vue.js"></script>
<!-- 引入樣式 -->
<link rel="stylesheet" href="/static/plugins/element-ui@2.2.1/lib/theme-chalk/index.css">
<!-- 引入組件庫 -->
<script src="/static/plugins/element-ui@2.2.1/lib/index.js"></script>
1) 容器須要增長id屬性javascript
2) 添加script標籤,創造vue組件css
<script type="text/javascript">vue
var app = new Vue({java
el: '#bm-sign',ios
data: {element-ui
form:{}axios
},app
watch: {}, ui
... spa
})
</script>
3)如需使用axios,直接引入便可:
<script src="/static/plugins/axios@0.18.0/dist/axios.min.js"></script>
app.form便可,如
for (var obj in app.form) {}