test等于''空字符串,想当然的以为test会被隐式转换成false,其实并没有,想要直接拿空字符做判断,自己加下布尔值转换:disabled="!!test"即可!
posted on 2021-10-20 15:36 ggfe 阅读(70) 评论(0) 收藏 举报