Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let m;
- const isThai = (str) => {
- const regexThai = /([\u0E00-\u0E7F]+)/gmu;
- const found = str.match(regexThai);
- if (!found) return false;
- return true;
- };
- const str = `engภาษาไทยที่มีสระ123!@`;
- const str2 = "asdSD";
- console.log(isThai(str2));
Advertisement
Add Comment
Please, Sign In to add comment