diff --git a/src/utils/helper.js b/src/utils/helper.js new file mode 100644 index 0000000..b58fbdf --- /dev/null +++ b/src/utils/helper.js @@ -0,0 +1,15 @@ +import moment from 'moment'; + +export const formatDate = (dateString) => { + + if (dateString) { + const date = moment(dateString); + return date.format('DD-MM-YYYY HH:mm'); + } + + return ''; +} + +export const decode = (value) => { + return value.replace(/_/g, " "); +}