绑定手机号 思路
手机号 tel
验证码 code
时间 time 60
时间为time == 0 ? '发送验证码' : '重新发送'+time+秒
点击发送验证码 click
手机号要有 tel !== ''
手机号要正确 正则验证 tel === true
时间 time == 0
const data = 都没问题 执行 发送验证码请求 post
if(!data) return; 请求结果没错,有值继续
开启时间倒计时
setinval({
时间 time--
if(如果时间 time === 0 ){
清除定时器
}
},1000)