@synotech/utils
Version:
a collection of utilities for internal use
13 lines (12 loc) • 470 B
TypeScript
/**
* This method validates email address
* @module dateFormat
* @param {date} date - a date object
* @param @param {"full" | "long" | "short" | "time"} format - The format of the output.
* @return {object} {Object} a well structured json object
* @example
*
* dateFormat(new Date(), 'full') // returns 'Sun, Jan 3rd 2021 20:00:00'
*
*/
export declare const dateFormat: (date: any, format?: "full" | "long" | "short" | "time" | undefined) => any;