Skip to content

Double value appear in textarea when using render function to create in .vue file. #7480

Open
@Fuji-sunny

Description

@Fuji-sunny

Version

2.5.13

Reproduction link

https://jsfiddle.net/SunnyLyu/ntoboxev/

Steps to reproduce

  1. sorry for things that it could not use .vue file definition in jsfiddle, please follow the steps below.

  2. to create a textarea component like this:

    export default {
    props: {
    value: {
    type: String
    }
    },
    render: function(h) {
    var _this = this;
    return h('textarea', {
    'on': {
    'input': function(e){
    _this.$emit('update:value', e.target.value);
    }
    }
    })
    }
    };

  3. import into a .vue file and use as a Vue component:

  1. run all these codes

What is expected?

Type '1' in textarea once, a character '1' would appear in the textarea, in IE11.

What is actually happening?

Type '1' in textarea once, 2 characters '11' would appear in the textarea at the same time, in IE11.


  1. Just use the component definition in HTML, everything goes well in both IE and Chrome (like the example running in jsfiddle).

  2. Once when using the definition in .vue file, after compiled would get wrong in IE11, but still ok in Safari and Chrome.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions