<!--第一种:点击改变容器的值-->
<li>
<a href="javascript:void(0)" @click="state.box_status = 'language'">语言</a>
</li>
<li>
<a href="javascript:void(0)" @click="state.box_status = 'equipment'">设备</a>
</li> <!--与容器的值相对应则显示-->
<div v-show="state.box_status == 'language'">
视图一
</div>
<div v-show="state.box_status == 'equipment'">
视图二
</div>
<!--第二种:点击改变容器的值-->
<select v-model="state.user_arg">
<option value="1">添加参数</option>
<option value="2">替换所有参数</option>
<option value="3">移除与以下内容完全一致的参数</option>
</select>
<div v-show="state.user_arg == 1">
视图一
</div> <div v-show="state.user_arg == 2">
视图二
</div> <div v-show="state.user_arg == 3">
视图三
</div>
<!--如果判断语句少写一个等号,会报 You may have an infinite update loop in a component render function 大意是无限更新循环--> 第一次写好紧张