如何进行日期选择器自定义?
大家好,我需要我的日期选择器可以有美国时间表年、月、日,因为它以拉丁时间显示,我该如何配置它。
我还需要我的日期选择器像这样显示 2022-03-02 并且不显示 2022/03/02 你能帮我吗?
Hello to all the community, I need that my datepicker can have the american timetable year, month, day because it appears in latin time, how can I configure that.
I also need that my datepicker shows like this
2022-03-02 and not to show 2022/03/02 can you help me?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 Angular Material 文档中,您可以在国际化部分了解如何配置日期选择器: https: //material.angular.io/components/datepicker/overview#internationalization
另请参阅 MomentDateModule 格式部分:
您可以从此处记录的解析格式中进行选择:
https://momentjs.com/docs/#/parsing/string-format/< /a>
In the Angular Material documentation you can see how to configure the datepicker, at internationalization section: https://material.angular.io/components/datepicker/overview#internationalization
See also MomentDateModule formats section:
You can pick from the parse formats documented here:
https://momentjs.com/docs/#/parsing/string-format/