Hi everyone
this is my work
this is my code:
I don’t understand the error can I get some explication ?
thanks
Hi everyone
this is my work
I don’t understand the error can I get some explication ?
thanks
cursor.x=event.ClientX/sizes.width
From Program Structure :: Eloquent JavaScript —
The word
const
stands for constant . It defines a constant binding, which points at the same value for as long as it lives.
Instead of const cursor
use let cursor
or (as I think you probably intended) modify cursor.x
and not the variable itself:
cursor.x = event.clientX / sizes.width;
thanks guys