-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Closed
Labels
Description
Hello :)
Could we change the docs for keyIsPressed to not be checked against true explicitly?
It is on: https://p5js.org/reference/#/p5/keyIsPressed
How would this new feature help
Avoiding to teach new devs bad coding-habit:
function draw() { if (keyIsPressed === true) { fill(0); } else { fill(255); } rect(25, 25, 50, 50); }
Most appropriate sub-area of p5.js?
- Documentation
Feature enhancement details:
function draw() { if (keyIsPressed) { fill(0); } else { fill(255); } rect(25, 25, 50, 50); }