Skip to content

Instantly share code, notes, and snippets.

@kessler
Created December 18, 2017 23:36
Show Gist options
  • Save kessler/e88ed9b36c8a208f58ef0f87a716cd13 to your computer and use it in GitHub Desktop.
Save kessler/e88ed9b36c8a208f58ef0f87a716cd13 to your computer and use it in GitHub Desktop.
format javascript date to pg timestamp with timezone
moment.utc(new Date()).format('YYYY-MM-DDTHH:mm:ss.SSSSSSSSS[Z]')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment