function drawCanvasContent(){ createCanvas(windowWidth, windowHeight) background(255) for (let i = 0; i <= 50; i++) { fill(0, 0, 0, 0) square(random(width/2), random(height/2), random(width/8, width/2)) } } function setup() { drawCanvasContent(); } function mouseMoved() { drawCanvasContent(); }