import handleformatdate as handleformatdate in react js code example Example: react date format npm install moment --save