You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ant-design/components/datepicker/demo/formatter.md

16 lines
324 B
Markdown

10 years ago
# 日期格式
- order: 1
10 years ago
使用 `format` 属性,可以自定义你需要的日期显示格式,如 `yyyy/MM/dd`
10 years ago
---
````jsx
import { Datepicker } from 'antd';
10 years ago
9 years ago
ReactDOM.render(
<Datepicker defaultValue="2015/01/01" format="yyyy/MM/dd" />
10 years ago
, document.getElementById('components-datepicker-demo-formatter'));
````