let pattern = /^[u4e00-u9fa5]{1,10}$/g; //检测1-10位汉字 pattern.test('啊啊啊啊啊'); let pattern = /^[u4e00-u9fa5]{1,250}$/g; //检测1-250位汉字 pattern.test('啊啊啊啊啊');
2.1m questions
2.1m answers
60 comments
57.0k users