Created
February 24, 2017 18:59
-
-
Save jesperlandberg/4502430cc685a5f558561ce0da2463d5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this.current == (this.total - 1) ? (this.current = 0 && this.prev = (this.total - 1)) : (this.current += 1 && this.prev = (this.current - 1)) | |
if(this.current == (this.total - 1)) { | |
this.current = 0 | |
this.prev = (this.total - 1) | |
} else { | |
this.current += 1 | |
this.prev = (this.current - 1) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment