ant-design/components/datepicker/demo/time.md

22 lines
378 B
Markdown
Raw Normal View History

2015-05-29 21:07:46 +08:00
# 时间选择
- order: 4
2015-06-02 17:20:02 +08:00
2015-11-19 14:28:54 +08:00
和 [时间选择组件](/components/timepicker) 配合使用。
2015-05-29 21:07:46 +08:00
---
````jsx
2015-11-19 14:28:54 +08:00
import { Datepicker, Timepicker } from 'antd';
2015-05-29 21:07:46 +08:00
2015-11-19 14:28:54 +08:00
function onChange(value) {
console.log(value);
}
ReactDOM.render(<div>
<Datepicker onChange={onChange} />
<Timepicker onChange={onChange} />
</div>, document.getElementById('components-datepicker-demo-time'));
2015-05-29 21:07:46 +08:00
````