运行以下无法解析到href="{{site.name}}" 还是原值。为什么,如何让他解析出来<!DOCTYPE html><html><head><meta charset="utf-8"><title>Vue 测试实例 - 菜鸟教程(runoob.com)</title><script src="https://cdn.bootcss.com/vue/2.2.2/vue.min.js"></script></head><body><div id="app"> <ol> <li v-for="site in sites"> {{ site.name }} <a href="{{site.name}}">{{site.name}}</a> </li> </ol></div><script>new Vue({ el: '#app', data: { sites: [ { name: 'Runoob' }, { name: 'Google' }, { name: 'Taobao' } ] }})</script></body></html>
添加回答
举报
0/150
提交
取消