一个比较基础的验证 一行代码搞定 不过我这还是写成个方法吧
const VerifyInteger = function(value) { return /(^[1-9]\d*$)/.test(value); }