Is int or float number - Node.js Regular expression

Node.js examples for Regular expression:Validation

Description

Is int or float number

Demo Code

       intOrFloat : {//  ww  w  . j  a v  a  2 s  .  co  m
          validator : function(value) { 
              return /^\d+(\.\d+)?$/i.test(value); 
          }, 
          message : '' 
       },

Related Tutorials