Skip to content

Instantly share code, notes, and snippets.

@imjn
Last active September 25, 2018 04:07
Show Gist options
  • Save imjn/4e6aa8537b919ed1c87104517c0cdedb to your computer and use it in GitHub Desktop.
Save imjn/4e6aa8537b919ed1c87104517c0cdedb to your computer and use it in GitHub Desktop.
indexの値がすでにあってslideSwiper()がしっかり動くのであればこれで行けそうな感じがするのですが...
function slideSwiper(index) {
var w = $(window).width();
var x = 768;
if (w < x) {
swiper.slideTo(index);
} else {
swiper.slideTo(index+2);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment