Skip to content

Bug with dynamic binding multiple for select tag. #4755

@34x

Description

@34x

Hello! First of all thank you for the great framework and your work.

I faced issue when tried to use select html tag with binded multiple attribute. But it does not work.
I have example on jsfiddle: https://jsfiddle.net/jqybwngo/

Partially copy bellow:

<div id="app">
  <select v-model="option" v-bind:multiple="isMultiple">
    <option value="1">item 1</option>
    <option value="2">item 2</option>
  </select>
</div>

And here is the error log from Safari (same for Firefox):
screen_2017_01_18_19_52_16

(found in root instance)
	warn (vue.js:525)
	setSelected (vue.js:5691)
	componentUpdated (vue.js:5672)
	callHook$1 (vue.js:4746)
	(anonymous function) (vue.js:4702)
	patchVnode (vue.js:4461)
	updateChildren (vue.js:4364)
	patchVnode (vue.js:4448)
	patch (vue.js:4572)
	_update (vue.js:2646)
	updateComponent (vue.js:2613)
	get (vue.js:2936)
	run (vue.js:3005)
	flushSchedulerQueue (vue.js:2811)
	(anonymous function) (vue.js:477)
	nextTickHandler (vue.js:426)
	promiseReactionJob
[Error] TypeError: binding.value.some is not a function. (In 'binding.value.some(function (v) { return hasNoMatchingOption(v, el.options); })', 'binding.value.some' is undefined)
componentUpdated — vue.js:5678
callHook$1 — vue.js:4746
https://unpkg.com/vue
patchVnode — vue.js:4461
updateChildren — vue.js:4364
patchVnode — vue.js:4448
patch — vue.js:4572
_update — vue.js:2646
updateComponent — vue.js:2613
get — vue.js:2936
run — vue.js:3005
flushSchedulerQueue — vue.js:2811
https://unpkg.com/vue
nextTickHandler — vue.js:426
promiseReactionJob

	logError (vue.js:439)
	promiseReactionJob

What is Expected?

Option is filled by array of selected values

What is actually happening?

Error reported in log, no parameter assigned.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions