Regex 10 solamente
@"^\d{10}$"
Fierce Flamingo
@"^\d{10}$"
export const onlyNumbersAndLetters = (value) => {
if(value)
return value.replace(/[^a-zA-Z0-9]/g, '');
}
console.log(`12331: ${/^\d+$/.test('12331')}`) // true
console.log(`abc: ${/^\d+$/.test('abc')}`) // false