Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // main.js
- Vue.config.errorHandler = function (err) {
- console.warn(err.message) //
- }
- // App.vue
- <template>
- // ...
- <button @click="login">Login</button>
- </template>
- <script>
- // ...
- @Component
- export default class App extends Vue {
- created() {
- throw new Error('Error during component creation')
- }
- async login() {
- const token = await api.loginUser(this.email, this.password)
- // ...
- }
- }
- </script>
Add Comment
Please, Sign In to add comment