Closed GoogleCodeExporter closed 9 years ago
It's the unary + operator. It has the same effect as
new Date().getTime()
i.e. returning the current date as a number.
Original comment by chengh...@gmail.com
on 13 Aug 2010 at 2:23
Ok, so the problem is solved by changing the line to:
var uniqueId = 1, data = [], expando = "_da" + new Date().getTime();
If compression is enabled, the whitespaces are removed, so that "_da" + +new
Date();" get's to "_da"++new Date();" what leads to an error.
Original comment by robert.w...@googlemail.com
on 13 Aug 2010 at 2:40
May I ask which compressor do you use?
The official compressed version uses YUI Compressor, which is smart enough to
leave a space between the pluses.
Also, you'll need to add the /*@cc_on!@*/ back into the code, or your
compressed DA won't work properly in IE.
Original comment by chengh...@gmail.com
on 13 Aug 2010 at 2:57
Original issue reported on code.google.com by
robert.w...@googlemail.com
on 13 Aug 2010 at 10:03