Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created May 4, 2021 20:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/8e40b8f0fef05fb491ceab4e8db0e4a1 to your computer and use it in GitHub Desktop.
Save parzibyte/8e40b8f0fef05fb491ceab4e8db0e4a1 to your computer and use it in GitHub Desktop.
// https://parzibyte.me/blog
const formateador = new Intl.DateTimeFormat('es-MX', { dateStyle: 'medium', timeStyle: 'medium' });
const fecha = new Date();
const fechaFormateada = formateador.format(fecha);
console.log("La fecha formateada es:\n" + fechaFormateada);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment