在react中,处理input输入框的时候,遇到输入法切为中文时,输入时会导致程序对当前用户输入字符实际长度的误判
采用compositionstart、compositionend来捕获IME(input method editor)的启动和关闭事件
在react中,处理input输入框的时候,遇到输入法切为中文时,输入时会导致程序对当前用户输入字符实际长度的误判
采用compositionstart、compositionend来捕获IME(input method editor)的启动和关闭事件
转载于:https://www.cnblogs.com/yuan-luo/p/7922161.html