美文网首页
react native 关于两种引擎引出问题

react native 关于两种引擎引出问题

作者: glenlg | 来源:发表于2019-09-30 10:25 被阅读0次

date 函数在移动和电脑端两个引擎下表现差异,使结果展现不一致.
问题表现:正常运行与remote debug下分别表现出两个结果.
e.g. : 移动 new Date('11/07')=>null
电脑: new Date('11/07')=>Sun Nov 04 2001 00:00:00 GMT+0800
解决:用标准的时间格式new Date('11-07')

相关文章

网友评论

      本文标题:react native 关于两种引擎引出问题

      本文链接:https://www.haomeiwen.com/subject/owgquctx.html