Skip to content

Commit a00170c

Browse files
committed
remove unnecessary appear check in v-show (fix vuejs#3559)
1 parent ada90e5 commit a00170c

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/platforms/web/runtime/directives/show.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export default {
1414
bind (el: any, { value }: VNodeDirective, vnode: VNodeWithData) {
1515
vnode = locateNode(vnode)
1616
const transition = vnode.data && vnode.data.transition
17-
if (value && transition && transition.appear && !isIE9) {
17+
if (value && transition && !isIE9) {
1818
enter(vnode)
1919
}
2020
const originalDisplay = el.style.display === 'none' ? '' : el.style.display

test/unit/features/transition/transition.spec.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -504,6 +504,7 @@ if (!isIE9) {
504504
// should not apply transition on initial render by default
505505
expect(vm.$el.textContent).toBe('foo')
506506
expect(vm.$el.children[0].style.display).toBe('')
507+
expect(vm.$el.children[0].className).toBe('test')
507508
vm.ok = false
508509
waitForUpdate(() => {
509510
expect(vm.$el.children[0].className).toBe('test test-leave test-leave-active')

0 commit comments

Comments
 (0)