Created
October 21, 2016 09:01
-
-
Save kbshl/ccdf2ebb6c343d704800f28aa766e432 to your computer and use it in GitHub Desktop.
Escaping chars in MomentJS's format() - From http://stackoverflow.com/questions/28241002/moment-js-include-text-in-middle-of-date-format
Origin: http://momentjs.com/docs/#escaping-characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// escape it with square brackets | |
moment().format('MMM. D, YYYY [at] h:mm A z'); | |
// produces: "Jan. 30, 2015 at 2:46 PM " |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment