Skip to content

Commit

Permalink
fix(runtime-dom): fix option selected update
Browse files Browse the repository at this point in the history
  • Loading branch information
Doctor-wu committed Jan 24, 2024
1 parent f1068fc commit e8e92c4
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions packages/runtime-dom/src/directives/vModel.ts
Expand Up @@ -3,6 +3,7 @@ import {
type DirectiveHook,
type ObjectDirective,
type VNode,
isReactive,
nextTick,
warn,
} from '@vue/runtime-core'
Expand Down Expand Up @@ -239,11 +240,6 @@ function setSelected(
return
}

// fast path for updates triggered by other changes
if (isArrayValue && looseEqual(value, oldValue)) {
return
}

for (let i = 0, l = el.options.length; i < l; i++) {
const option = el.options[i]
const optionValue = getValue(option)
Expand Down

0 comments on commit e8e92c4

Please sign in to comment.