RangeError: Invalid time value

前端 未结 1 1152
一整个雨季
一整个雨季 2021-02-20 13:02

I\'m getting frequent errors when i start my server. Here is the error:

RangeError: Invalid time value at Date.toISOString ()

Here is the

1条回答
  •  醉话见心
    2021-02-20 13:26

    This exception occurs when the Date object contains an invalid date.

    new Date('undefined').toISOString()
    

    In this example the Date object can be created without any problems, but the toISOString function throws an Error.

    To fix your issue, you need to make sure that the timestamp variable contains a valid date string.

    0 讨论(0)
提交回复
热议问题