Create detect_swipe.js