2
0
mirror of https://github.com/tenrok/vue2-datepicker.git synced 2026-06-24 02:20:36 +03:00

Merge branch 'fix-typo-error' of https://github.com/ansidev/vue2-datepicker into ansidev-fix-typo-error

This commit is contained in:
mengxiong10
2020-01-10 09:50:25 +08:00
+2 -2
View File
@@ -191,14 +191,14 @@ import 'vue2-datepicker/locale/zh-cn';
`format` 接受一个对象去自定义格式化 `format` 接受一个对象去自定义格式化
```html ```html
<date-picker :format="momentForamt" /> <date-picker :format="momentFormat" />
``` ```
```js ```js
data() { data() {
return { return {
// 使用moment.js 替换默认 // 使用moment.js 替换默认
momentForamt: { momentFormat: {
// Date to String // Date to String
stringify: (date) => { stringify: (date) => {
return date ? moment(date).format('LL') : '' return date ? moment(date).format('LL') : ''