发布于 4年前

bootstrap-datetimepicker 火狐浏览器报错

使用bootstrap-datetimepicker日期选择插件时发现在火狐浏览器下报错:

未压缩版报错: ref is undefined
压缩版报错: m is undefined

打开未压缩的版本,定位到59行左右

formattedStr = ((ref = date.split('(')[1]) !== null ? ref.slice(0, -1) : 0) || date.split(' ');
改为

formattedStr = ((ref = date.split('(')[1]) != null ? ref.slice(0, -1) : 0) || date.split(' ');
就可以了。

©2020 edoou.com   京ICP备16001874号-3