📅  最后修改于: 2022-03-11 15:03:48.977000             🧑  作者: Mango
function validateResourceName(string) {
var pattern = /(\w)*\\(?!\\)(\w)*\\(?!\\)(\w)*(?!\\)/g;
if (!pattern.test(string)) {
alert("not a match");
} else {
alert("match");
}
}
if(JWS_REGEX.test('abc')){
console.log('valid token')
} else {
console.log('not valid');
}