JSFiddle - React, Tailwind, and code Playground

JavaScript

var x = 5.0364342423;
alert(x.toFixed(2));