From 3abb2981ecfd202158391de7499c28c7a75d6033 Mon Sep 17 00:00:00 2001 From: Yanzhen Yu Date: Sat, 12 Sep 2020 17:28:29 +0800 Subject: [PATCH] close #322 hook select element selectedIndex property --- src/record/observer.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/record/observer.ts b/src/record/observer.ts index b60508eb..8c364d35 100644 --- a/src/record/observer.ts +++ b/src/record/observer.ts @@ -292,6 +292,8 @@ function initInputObserver( [HTMLInputElement.prototype, 'checked'], [HTMLSelectElement.prototype, 'value'], [HTMLTextAreaElement.prototype, 'value'], + // Some UI library use selectedIndex to set select value + [HTMLSelectElement.prototype, 'selectedIndex'], ]; if (propertyDescriptor && propertyDescriptor.set) { handlers.push(