AI助手支持GPT4.0
微信开发工具列表使用sort排序,iOS端无法正常使用?The list of WeChat development tools is sorted by sort, but the iOS terminal cannot be used normally?
微信开发工具列表使用sort排序,iOS端无法正常使用?
crash.crashList.sort((a,b)=>{ let aTime = new Date(a.time); let bTime = new Date(b.time); return bTime.getTime() - aTime.getTime(); })
s上面的排序代码,模拟器调试和Android iOS真机调试都正常,但是发布后使用iOS端打开排序就会乱掉,Android端又是正常的
下面是排序正常的
crash.crashList.sort ((a,b)=>{ let aTime = new Date(a.time); let bTime = new Date(b.time); return bTime.getTime () - aTime.getTime (); The sorting code above, simulator debugging and Android IOS real machine debugging are all normal, but the sorting will be disordered after opening the IOS side after release. The Android side is normal again, and the following is normal
IOS下日期的-要改成/再去获取时间戳,不然会是null