JSFiddle - React, Tailwind, and code Playground

JavaScript

var mydate = new Date("Feb 17, 2012");
var newdate = mydate.getDate() + '/' + ("0" + (parseInt(mydate.getMonth())+1)).slice(-2) + '/' + mydate.getFullYear();
alert(newdate);