UNPKG

verificator

Version:

Client and server-side validation JavaScript library

6 lines (5 loc) 197 B
const isNumeric = (value) => { const type = typeof value; return (type === 'number' || type === 'string') && !isNaN(Number(value) - parseFloat(String(value))); }; export default isNumeric;