import dayjs from "dayjs";
const typeDetection = (data) => {
  return Object.prototype.toString.call(data).replace(/\[object\s(\w+)\]/, "$1").toLowerCase();
};
const formatDate = (stamp, type) => {
  if (!stamp)
    return "";
  return dayjs(+stamp).format(type);
};
export { formatDate as f, typeDetection as t };
