javascript - Error using v-else-if in vue
阿神
阿神 2017-07-05 11:04:54
0
1
1362
<td v-if = 'item.edit && onlyShowInROBOTTYPE '>
    <input type="text" class='form-control'     v-model= 'item.content.prefix'>
</td>
<td v-else-if='onlyShowInROBOTTYPE' >
    {{item.prefix}}
</td>

onlyShowInROBOTTYPE是一个计算属性  返回bool值

提示 vendor.js:32459 [Vue warn]: Failed to resolve directive: else-if.

阿神
阿神

闭关修行中......

reply all(1)
巴扎黑

Please check whether the Vue version in your node_modules directory is greater than 2.1.0. This feature does not exist in 2.0.x.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template