Switching to vanilla JS