title: Can't refresh data when user login using Vue.js
body: <p>I'm new to Vue and firebase.</p>
  
  <p>I want to refresh my data when user is logged in.
  I'm thinking about making a refresh method and trigger it <code>onAuthStateChanged</code>, but it just doesn't work( ERR: not defined ).</p>
  
  <p>Below is my code, this is in an component file.</p>
  
  <pre><code>let auth = Firebase.auth()
  auth.onAuthStateChanged(function (user) {
    if (user) {
      refresh(user.uid,user.displayName)
    }
  }
  
  export default {
    name: 'chat_app',
    firebase: {...},
    data () {
      return {
        dialogNumber: 1,
        currentUserId: 1,
        currentUserName: 'A',
        ...
    },
    methods: {
      refresh: function (uid,displayName) {
        this.currentUserId = uid
        this.currentUserName = displayName
      }
    }
  }
  </code></pre>