Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 google-libphonenumber 来确定一个大文本字符串是否包含电话号码,如果我使用“isValidNumber”,那么它只需要一个电话号码字符串,而不是一个完整的“可能”包含的大文本字符串电话号码。
所以,我的查询是当我有一大串可能包含电话号码的文本时使用 google-libphonenumber 的哪个功能。
PS:我必须在javascript中处理这个。
似乎已经问过类似的问题
Javascript RegExp - 从字符串中提取电话号码
检查那里的答案,他们可能会给你你需要的东西。