Hello! Can anyone advise what this Javascript symbol is at if (event.key == Is it supposed to be two equal signs?
Hi @delorisinar!
I’m not exactly sure what your question is, but maybe the page below can help you.
https://developer.playcanvas.com/en/api/pc.KeyboardEvent.html
Hello @delorisinar
I guess you have confusion with single equals to sign and double equals to sign…
- Single equals to sign is used to assign value. [ e.g. var myVar = 10]
- Double equals to sign is used to compare values. [ e.g. if(myVar == 5) ]
You can take a look at following link in case if you need in depth info…
Difference Between =, ==, and === in JavaScript [Examples]
2 Likes
Perfect, thank you both for these resources! I’ve bookmarked them for future reference.