just number regex js
snippet in javascript

just number regex js

user9796

// https://regex101.com/r/qyq3PG/1
// or 
/^[0-9]*$/

number pattern js

user4142

/^[\+\-]?\d*\.?\d+(?:[Ee][\+\-]?\d+)?$/

/* 
	matched values:
    -2.14e10
    +14E-20
    42.69
*/