Home > Software engineering >  Repeating function calls
Repeating function calls

Time:10-23

When i change a frame size, like 3x3, 4x4, 5x5 etc. canvas draw n number of times constantly calculation in progression. I can't figure out where the error might be. Can you help me fix this bug. I suspect that the problem is in the function call in the class, or in one of the functions.

Code snippet and screenshot picture i attached

Error

You can delete event by using EventTarget.removeEventListener()

Or

By replacing node box.replaceWith(box.cloneNode(true));

  • Related