display: none: 标签不会出现在页面上(尽管你仍然可以通过dom与它进行交互)。其它标签不会为它分配空间。visibility:hidden: 标签会出现在页面上,只是看不见而已。其它标签会为它分配空间。
display: none
visibility:hidden
v-if: 真正的条件渲染。false,不在dom中。v-show: 一直在dom中,只是用css的display属性进行切换(存在于html结构中,但是未用css进行渲染)。存在dom结构中,display:none时,不在render(渲染树)树中。
v-if
v-show
display:none