Element: [Bug Report] input does not support setSelectionRange method.

Created on 14 May 2018  ·  4Comments  ·  Source: ElemeFE/element

Element UI version

2.3.8

OS/Browsers version

Chrome 65.0.3325.181

Vue version

2.5.16

Reproduction Link

https://jsfiddle.net/SongZeng/mmx38qxw/1937/

Steps to reproduce

对 input 使用 setSelectionRange 方法无效,提示 this.$refs.input.setSelectionRange is not a function

What is Expected?

希望 input 支持 setSelectionRange 方法

What is actually happening?

this.$refs.input.setSelectionRange is not a function

Most helpful comment

需要在原生 input 元素上执行:https://jsfiddle.net/mmx38qxw/1938/

All 4 comments

Translation of this issue:

Element UI version
2.3.8

OS/Browsers version
Chrome 65.0.3325.181

Vue version
2.5.16

Reproduction Link
https://jsfiddle.net/SongZeng/mmx38qxw/1937/

Steps to reproduce
Invalid for input using setSelectionRange method, suggesting this.$refs.input.setSelectionRange is not a function

What is Expected?
Hope input supports the setSelectionRange method

What is actually happening?
This.$refs.input.setSelectionRange is not a function

需要在原生 input 元素上执行:https://jsfiddle.net/mmx38qxw/1938/

OK,希望能在文档里添加上说明

需要在原生 input 元素上执行:https://jsfiddle.net/mmx38qxw/1938/

I don't understand the language but the answer was in the fiddle, thank you !

Was this page helpful?
0 / 5 - 0 ratings

Related issues

no5no6 picture no5no6  ·  3Comments

chao-hua picture chao-hua  ·  3Comments

yuchonghua picture yuchonghua  ·  3Comments

makunsusu picture makunsusu  ·  3Comments

FranzSkuffka picture FranzSkuffka  ·  3Comments