-
• #2
I am seeing that it is as easy as adding to .toString() to get the format xxx Feb xx 2023 h:mm:ss GMT+0100
console.log("pressDate "+pressDate.toString());
for some reason when using the Date.now() the to String was implicit
-
• #3
I think it's the difference between these two?
console.log("converted Date.now"+keyDate); console.log("converted Date.now",keyDate);
-
• #4
Yes, you are right
Not good to read/write code at afternoon, if i read 100 times, I wouldn't see this different character/operator...
Also i was sure that all console.log were based in copy/paste and using the same operator....
After some testing I've realize that epoch time from Date.now() and returned from setWatch() are different, and yes it is documented that 2nd one is using float.
I wanted to see in human readable format, and i can do for the result of Date.now(), ie:
But I have problems with console.log when using the float from setWatch()
On the other hand, from the IDE console, when i assign the previous float*1000 to a var I can see a human readable value, i.e
I am sure that there is an easy explanation and my issue is causes from the lack of theoretical basics.