UNPKG

tnt-form

Version:
8 lines (5 loc) 463 B
"use strict"; var util = {}; /* email regex, not entirely RFC compliant, but pretty close. TLDs (> 2 chars) need to be added when more become available. */ util.RE_EMAIL = /^[-a-z0-9~!$%^&*_=+}{\'?]+(\.[-a-z0-9~!$%^&*_=+}{\'?]+)*@([a-z0-9_][-a-z0-9_]*(\.[-a-z0-9_]+)*\.(aero|flights|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|mobi|[a-z][a-z])|([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))(:[0-9]{1,5})?$/i; module.exports = util;