uniapp输入空格

uniapp   密码框输入空格(去除空格)的时候一直回显不及时  经过一番折腾 终于搞定

1.先赋值:     this.pwd = e.detail.value

2. 使用setTimeout(再次赋值 )

 setTimeout(() => { this.pwd = e.detail.value;this.pwd=this.pwd.replace(/s+/g,'');}, 0)

原文地址:https://www.cnblogs.com/j190512/p/13304432.html