当前位置:网站首页>解决el-input输入框.number数字输入问题,去掉type=“number“后面箭头问题也可以用这种方法代替
解决el-input输入框.number数字输入问题,去掉type=“number“后面箭头问题也可以用这种方法代替
2022-07-04 15:39:00 【是啦啦啦呀】
解决element输入框.number数字输入问题
提示:去掉type="number"后面箭头问题也可以用这种方法代替:
例如:规定输入框只能输入数字,在v-model后加.number会出现只有最开始就输入字符,可以输入字符的情况
提示:以下是本篇文章正文内容,下面案例可供参考
解决方法1:onkeypress
利用正则进行验证
onkeypress="return( /^\d$/.test(String.fromCharCode(event.keyCode) ) )"
解决方法2:@input,注意绑定的值跟自定义方法里的保持一致即可


边栏推荐
- Summary of tx.origin security issues
- La 18e Conférence internationale de l'IET sur le transport d'électricité en courant alternatif et en courant continu (acdc2022) s'est tenue avec succès en ligne.
- 【测试开发】软件测试——基础篇
- What grade does Anxin securities belong to? Is it safe to open an account
- 线性时间排序
- Array filter fliter in JS
- CANN算子:利用迭代器高效实现Tensor数据切割分块处理
- Zebras are recognized as dogs, and the reason for AI's mistakes is found by Stanford
- VSCode修改缩进不成功,一保存就缩进四个空格
- 电子宠物小狗-内部结构是什么?
猜你喜欢

It's too convenient. You can complete the code release and approval by nailing it!

超大规模数仓集群在大型商业银行的落地实践

智捷云——元宇宙综合解决方案服务商

开发者,MySQL专栏完更,助你轻松从安装到入门进阶

Chow Tai Fook fulfills the "centenary commitment" and sincerely serves to promote green environmental protection

leetcode:421. The maximum XOR value of two numbers in the array

Visual Studio 2019 (LocalDB)MSSQLLocalDB SQL Server 2014 数据库版本为852无法打开,此服务器支持782

居家打工年入800多万,一共五份全职工作,他还有时间打游戏

Implementation of super large-scale warehouse clusters in large commercial banks

Go micro tutorial - Chapter 2 go micro V3 using gin and etcd
随机推荐
Firewall basic transparent mode deployment and dual machine hot standby
kaili不能输入中文怎么办???
Readis configuration and optimization of NoSQL (final chapter)
中信证券网上开户安全吗 开户收费吗
Internet addiction changes brain structure: language function is affected, making people unable to speak neatly
Start by counting
detectron2安装方法
Is it safe for Great Wall Securities to open an account? How to open a securities account
C# 服务器日志模块
VMware Tools和open-vm-tools的安装与使用:解决虚拟机不全屏和无法传输文件的问题
[template] [Luogu p4630] duathlon Triathlon (round square tree)
Using win10 scheduling task program to automatically run jar package at fixed time
【模板】【luogu P4630】Duathlon 铁人两项(圆方树)
Two methods of MD5 encryption
智慧物流園區供應鏈管理系統解决方案:數智化供應鏈賦能物流運輸行業供應鏈新模式
Jump table instance
Go micro tutorial - Chapter 2 go micro V3 using gin and etcd
基于wifi控制的51单片机温度报警器
Summary of tx.origin security issues
Kunming Third Ring Road Closure project will pass through these places. Is there one near your home?