코드에 보통 영어로 많이 사용하기에 한글이 입력을 받지 않지만 혹시 한글이 입력될 경우 script에서 검증을 해야한다.

 

const korean = /[ㄱ-ㅎ|ㅏ-ㅣ|가-힣]/;
korean.test(string);

+ Recent posts