代码 dayjs版本1.11.7
页面
当点击页面日期框会报clone.weekday is not a function
解决方法 在jsx文件中添加如下js
import dayjs from dayjs;
import advancedFormat from dayjs/plugin/advancedFormat
import customParseFormat from dayjs/plugin/customParseFormat
…
form.setFieldsValue设置默认值 之后去选择日期 报错clone.weekday is not a function 解决方法:
import weekday from "dayjs/plugin/weekday"
import localeData from "dayjs/plugin/localeData"dayjs.extend(weekday)
dayjs.extend(localeData)来自:fo…
form.setFieldsValue 之后再去选择日期 出错clone.weekday is not a function 不需要重新装包, 你只需做下面的操作 :
import weekday from "dayjs/plugin/weekday"
import localeData from "dayjs/plugin/localeData"dayjs.extend(weekday)
dayjs.extend…