Last active
August 18, 2018 14:06
-
-
Save enkot/3bded6db9c9e05f0cf2924eb251c6ac6 to your computer and use it in GitHub Desktop.
promise.ts
This file contains hidden or 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
@Component | |
class LoginPage extends Vue { | |
// ... | |
loginUser() { | |
api.loginUser(this.email, this.password) | |
.then(handleLogin) | |
.catch(error => Toast.error(error.message)) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment