3 ms·The "pattern" attribute on an <input> can do that using regex.by SquareWheel 9y agoThe "pattern" attribute on an <input> can do that using regex.