标签:nic ace pac span cti mat 字符 func col
如下:
function codePointLength(text){ var result = text.match(/[\s\S]/gu); return result? result.length:0; } var s = ‘????‘;
s.length //4
codePointLength(s) //2
标签:nic ace pac span cti mat 字符 func col
原文地址:https://www.cnblogs.com/zeng-zhi/p/10167692.html