I want to run certain javascript only when the window width is over 1024. The script is long. I\'ve tried to combine them with
if ($(window).width() >= 1024
but