📅  最后修改于: 2022-03-11 14:48:24.948000             🧑  作者: Mango
代码示例1
var trigger = "2",
regexp = new RegExp('^[1-9]\d{0,2}$'),
test = regexp.test(trigger);
alert(test + ""); // will display true