This project demonstrates a simple JavaScript animation using Canvas where a circle follows the mouse cursor.
The animation is implemented using HTML canvas and JavaScript. The circle's position is updated continuously to follow the mouse cursor on the canvas. The animation loop is created using requestAnimationFrame() for smooth rendering.
Clone or download the repository to your local machine. Open the index.html file in a web browser.
The index.js file contains the JavaScript code responsible for setting up the canvas, tracking mouse movements, and drawing the circle. The mousemove event listener updates the position of the mouse cursor. The animate() function clears the canvas, calculates the new position of the circle based on the mouse position, and draws the circle on the canvas. The animation loop is initiated by calling the animate() function recursively using requestAnimationFrame().
This project is licensed under the MIT License - see the LICENSE file for details.