title: Async / Await on created method - Vue2
body: <p>I have <code>vue-element-loading</code> package, added it's component in my page.vue:</p>
  
  <pre><code>&lt;vue-element-loading :active="isActive" :is-full-screen="true"/&gt;
  </code></pre>
  
  <p>Added variable to data:</p>
  
  <pre><code>data () {
    return {
      isActive: false,
    }
  }
  </code></pre>
  
  <p>Then triggering <code>isActive</code> to <code>true</code> when the page finishes load:</p>
  
  <pre><code>async created () {
    this.isActive = true
    await this.fetchData()
    this.isActive = false
  }
  </code></pre>
  
  <p><code>fetchData</code> is an axios get request with response. Idea is to show loader, till axios properly fires and getting response. But now, my loader shows for 0.1 milliseconds, then disappears.</p>
  
  <p>Here's the <code>fetchData</code> method:</p>
  
  <pre><code>fetchData () {
    axios.get(globalConfig.OFFERS_URL)
      .then((resp) =&gt; {
        this.offersData = resp.data
        console.log(resp)
      })
      .catch((err) =&gt; {
        console.log(err)
      })
  },
  </code></pre>