Skip to content

Commit

Permalink
fix v-model on input[type=range] in IE (fix #3439)
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Aug 14, 2016
1 parent 854ccce commit 174e936
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/platforms/web/compiler/directives/model.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/* @flow */

import { isIE } from 'web/util/index'
import { addHandler, addProp, getBindingAttr } from 'compiler/helpers'

let warn
Expand Down Expand Up @@ -96,7 +97,7 @@ function genDefaultModel (

const type = el.attrsMap.type
const { lazy, number, trim } = modifiers || {}
const event = lazy ? 'change' : 'input'
const event = lazy || (isIE && type === 'range') ? 'change' : 'input'
const needCompositionGuard = !lazy && type !== 'range'
const isNative = el.tag === 'input' || el.tag === 'textarea'

Expand Down

0 comments on commit 174e936

Please sign in to comment.