Browse Source

fix: scoped slots dynamic check should include v-for on element itself

fix #9596
dev
Evan You 6 years ago
parent
commit
2277b2322c
  1. 2
      src/compiler/codegen/index.js

2
src/compiler/codegen/index.js

@ -366,7 +366,7 @@ function genScopedSlots (
// components with only scoped slots to skip forced updates from parent.
// but in some cases we have to bail-out of this optimization
// for example if the slot contains dynamic names, has v-if or v-for on them...
let needsForceUpdate = Object.keys(slots).some(key => {
let needsForceUpdate = el.for || Object.keys(slots).some(key => {
const slot = slots[key]
return (
slot.slotTargetDynamic ||

Loading…
Cancel
Save