Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在以下示例中,我想说 date-fns 不格式化at(跳过这些字符):
at
format(DATE, 'cccc, MMMM d at h:mm a')
输出是:
Thursday, August 8 AM492296400 12:30 AM
预期是:
Thursday, August 8 at 12:30 AM
请参阅文档:
包裹在两个单引号字符 (') 之间的字符被转义。
format(DATE, "cccc, MMMM d 'at' h:mm a")