max-mapper / yo-yo

A tiny library for building modular UI components using DOM diffing and ES6 tagged template literals
1.33k stars 65 forks source link

Why does yo-yo reset the value property of select elements? #58

Open aknuds1 opened 7 years ago

aknuds1 commented 7 years ago

I've noticed that yo-yo fiddles with the selection state of my select elements when I change which option is selected by setting its selected property.

By debugging, I figured out that it's due to this code. Should it instead copy from t to f? I don't understand why the mutating element should get modified, it seems the opposite should happen.