aboutsummaryrefslogtreecommitdiff
path: root/src/components/login_form/login_form.js
blob: b55f770f5d67edfb7393069e0bf892f23557905d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
const LoginForm = {
  data: () => ({
    user: {}
  }),
  computed: {
    loggingIn () { return this.$store.state.users.loggingIn }
  },
  methods: {
    submit () {
      this.$store.dispatch('loginUser', this.user).then(() => {
        this.$router.push('/main/friends')
      })
    }
  }
}

export default LoginForm