Skip to content

[DatePicker]: Moment.isMoment is not a function #5778

@nooooooom

Description

@nooooooom
  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

1.7.7

Environment

Windows10, Chrome 102.0.5005.115, Vue 2.6.14

Reproduction link

import * as moment from 'moment';

Steps to reproduce

Start with vite.

What is expected?

DatePicker working well.

What is actually happening?

An error has occurred, It's described as moment.isMoment is not a function.


The moment 2.21.0 doesn't support es module export, so import * as XX will have an error.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions