src/utils/helpers.js
// `lang` is optional and will default to the current user agent locale
`lang` is optional and will default to the current user agent locale
` lang ` is optional and will default to the current user agent locale
function formatpostDate(date, lang) {
  if (typeof Date.prototype.toLocaleDateString !== 'function') {
    return date;
  }
  date = new Date(date);
  const args = [
    lang,
    { day: 'numeric', month: 'long', year: 'numeric' },
  ].filter(Boolean);
  return date.toLocaleDateString(...args);
}
function formatpostDate ( date , lang ) { if ( typeof Date . prototype . toLocaleDateString !== 'function' ) { return date ; } date = new Date ( date ) ; const args = [ lang , { day : 'numeric' , month : 'long' , year : 'numeric' } , ] . filter ( Boolean ) ; return date . toLocaleDateString ( ... args ) ; }
`lang` is optional and will default to the current user agent locale
` lang ` is optional and will default to the current user agent locale