I created this photo slider where I am using a setInterval function to continuously change its x position. The problem is that the setInterval function starts taking lots of mem