0

How to parse float with two decimal places in javascript?

You can use toFixed() to do that:

var twoPlacedFloat = parseFloat('123').toFixed(2);
console.log(twoPlacedFloat);  // "123.00"
RUN
add comment
Suggest a different solution or add another example