I am trying to build a regex which will allow both negative and positive decimal numbers with the following rules.
/(?:^(?:(?:[1-9][0-9]{1,})|0)\.[0-9]{1,}$)|^[1-9]+[0-9]*$/