0👍
If you are using the same code in the documentation in the function mouseMove in the condition
if (this.dragEvent && this.dragTime != null)
change to
if (this.dragEvent && this.dragTime)
it works for me.
When i had this error, i checked the value of this.dragTime and it was undefined and the condition was true so i removed != null
and if this.dragTime is null or undefined never enter to the condition and you never receive a NaN
Source:stackexchange.com